COM object datasource

COM object datasource

Old forum URL: forums.lhotka.net/forums/t/7746.aspx


SeanD posted on Wednesday, October 07, 2009

Hi,
I have a COM object data source that is event-driven. I would like to hook this up to my CSLA business objects, to use those as a facade to the underlying data.

Basically, a parameter array is set up, and passed into the COM object, it returns immediately, and does a callback (to the event handler), when the results come back.

Is there a way to set up my DataPortal_Fetch to work with this?

I'm delving more deeply into the COM objects underlying code to figure out where the actual synchronous call is made, and I will (eventually) use that.

I'm sure, however, that this event-based COM approach has been investigate before by someone, as am I sure there'll be a case where I wont have access to the underlying C++ functions.

Any info greatly appreciated.

Regards,
Sean

ajj3085 replied on Thursday, October 08, 2009

Unless this is happening on the client, I don't think there's a way to do this. The reason is that the dataportal will return and your code will no longer be executing on the server.. and there's no way then to get the event bck to the client.

Copyright (c) Marimer LLC