Hello Olaf
I was using RC5 RPC connection via CRpcConnection
Regarding Olaf's advice.
What you forgot in the above Project-list, is the 3rd-Project:
- the Server-Dll-Project
BackGround:
- a loaded COM-Dll does not know about any "already regfree loaded instances in other binaries"
- it runs (in this regard) kind of "isolated from the Executable"
So, the same rules (regarding regfree-enabling) as for your Exes apply:
- switch the COM-Dll-Project-Settings, to "use a Sub Main()"
- introduce a *.bas Module which hosts Sub Main() in your Dll-Project
- now place the same regfree initializer-code there as in your Exe-Projects Sub Main()
So in order to take into account the regfree support, I added a module to the SQLiteServer.vbp with Sub Main that looks like this.
Everything was OK both in IDE and exe modes.
Now I'm using RC6.
My problem is that in IDE mode, I'm getting error: couldn't pre-load DirectCOM.dll
but after compilation everything is OK.
I wonder why? since they they are referring to the same SQLiteServer.dll and the same DirectCOM.dll.
What I "m doing now. I dropped the sub Main from the SQLiteServer.vbp and Kept just the cDBAccess.cls.
Everything works fine both in IDE and exe modes.
My question to Olaf and experts of RC6.
Are there any serious pitfalls for doing so
thank you
I was using RC5 RPC connection via CRpcConnection
Regarding Olaf's advice.
Quote:
What you forgot in the above Project-list, is the 3rd-Project:
- the Server-Dll-Project
BackGround:
- a loaded COM-Dll does not know about any "already regfree loaded instances in other binaries"
- it runs (in this regard) kind of "isolated from the Executable"
So, the same rules (regarding regfree-enabling) as for your Exes apply:
- switch the COM-Dll-Project-Settings, to "use a Sub Main()"
- introduce a *.bas Module which hosts Sub Main() in your Dll-Project
- now place the same regfree initializer-code there as in your Exe-Projects Sub Main()
Code:
Set New_c = GetInstanceFromBinFolder("vbRichClient5", "cConstructor")
Now I'm using RC6.
My problem is that in IDE mode, I'm getting error: couldn't pre-load DirectCOM.dll
but after compilation everything is OK.
I wonder why? since they they are referring to the same SQLiteServer.dll and the same DirectCOM.dll.
What I "m doing now. I dropped the sub Main from the SQLiteServer.vbp and Kept just the cDBAccess.cls.
Everything works fine both in IDE and exe modes.
My question to Olaf and experts of RC6.
Are there any serious pitfalls for doing so
thank you