Reputation: 33
I have a Delphi VCL application that manipulates a TClientDataset object. I need to pass this object as a parameter to a custom COM library, also written in Delphi.
I have two questions: 1) Is this possible? 2) If so, how?
Upvotes: 3
Views: 223
Reputation: 613282
No you cannot pass such an object. It is not a valid COM interop type. In fact you cannot even pass such an object between Delphi modules other than runtime packages.
The most obvious solutions are:
Data
and XMLData
properties of client data set. The latter two serialization based options are probably simpler. But more costly in terms of memory. Using an interface requires more work to code, but may result in more efficient runtime performance.
Upvotes: 3