Re: Reference multiple versions of VB6 DLL

Tech-Archive recommends: Fix windows errors by optimizing your registry




<dmitriy.melnik@xxxxxxxxx> schrieb im Newsbeitrag
news:1128350523.233377.185210@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

> Any other way I can separate those dll and reference it in my app
You can load different instances of your Dlls, if you instantiate them
without using the registry.
One Standard-Dll-Helper is needed (DirectCom.Dll from)
www.datenhaus.de/Downloads/dh_DirectCom.zip

Put the Dll into your App.Path and declare this Call:
Private Declare Function GETINSTANCE Lib "DirectCom" _
(FName$, CName$) As Object

Then you can change your instantiation-Lines to:
Dim objVers1 as YourClassType
Dim objVers2 as YourClassType

Set ObjVer1 = GETINSTANCE(FileNameVers1, ClassName)
Set ObjVer2 = GETINSTANCE(FileNameVers2, ClassName)

And even use both instances in parallel, if you need something like that.

Olaf


.



Relevant Pages

  • Re: Program execution while waiting for DLL return
    ... it's a buffer between your app and the DLL. ... ActiveX DLL. ... Private Declare Function GetCurrentProcess Lib "kernel32" As Long ... Public Sub InitializeTimerAndEnrollProcess() ...
    (microsoft.public.vb.general.discussion)
  • using the CWegPage.dll
    ... Unfortunately Dexterity cannot use OCX's to put on their windows such as VB ... what I've found is that for the most part what I can get VB6 working with I ... Basic 6 to work with this dll and see if I can get it working. ... Private Declare Function FreeLibrary Lib "kernel32.dll" (ByVal hLibModule As ...
    (microsoft.public.vc.language)
  • using the CWegPage.dll
    ... Unfortunately Dexterity cannot use OCX's to put on their windows such as VB ... what I've found is that for the most part what I can get VB6 working with I ... Basic 6 to work with this dll and see if I can get it working. ... Private Declare Function FreeLibrary Lib "kernel32.dll" (ByVal hLibModule As ...
    (microsoft.public.vb.winapi)
  • Re: DLL or OCX calls from VB
    ... I dont know if I am creating the .dll file wrong or not doing something else ... Dim myObj As String ... Private Declare Function GetProcAddress Lib "kernel32" (ByVal hModule As ... Dim hLib As Long ...
    (microsoft.public.vb.general.discussion)
  • Re: Check if DLL is registered
    ... > Is there any way to check whether or not a particular DLL is registered? ... > particular DLL is registered, and then if not, register it. ... > Private Declare Function FreeLibrary Lib "kernel32" (ByVal hLibModule As ...
    (microsoft.public.excel.programming)