I know I have done this before, many years ago.
We created an OLEVariant e.g.

   myADOConn := createoleobject('adoconnection.xxx');
   (or however it goes)

and then passed myADOConn thru to the dll and then it was able to be uses by the dll.

How I did it excactly, I cant remember, but I know that it worked :-)

Jeremy

-------- Original Message --------
Subject: [DUG] TADOConnection ConnectionObject sharing across dll
boundary
From: "Leigh Wanstead" <[EMAIL PROTECTED].nz>
Date: Wed, August 06, 2008 2:37 pm
To: "NZ Borland Developers Group - Delphi List" <[EMAIL PROTECTED].nz>

Good afternoon,

I have a exe application with multiple dlls. Each dll has a datamodule
including a TADOConnection. It takes around half seconds to run
TADOConnection.Connected := true I assume this is normal.

But all these time total up takes around several seconds which is too long.
I think that I only have one TADOConnection in one dll. And share the rest
with this TADOConnection. Can I just pass TADOConnection.ConnectionObject
around to share dll? My understanding is delphi object can not be shared
across dll. But _Connection should be ok, right?

BTW, what is the right way to share TADOConnection across dll boundary?

Have a nice day

Regards
Leigh


_______________________________________________
NZ Borland Developers Group - Delphi mailing list
Post: delphi@delphi.org.nz
Admin: http://delphi.org.nz/mailman/listinfo/delphi
Unsubscribe: send an email to delphi-request@delphi.org.nz with Subject: unsubscribe
_______________________________________________
NZ Borland Developers Group - Delphi mailing list
Post: delphi@delphi.org.nz
Admin: http://delphi.org.nz/mailman/listinfo/delphi
Unsubscribe: send an email to [EMAIL PROTECTED] with Subject: unsubscribe

Reply via email to