Board index » delphi » StdPicture = IPicture + IPictureDisp
Grinder
Delphi Developer |
Sun, 15 May 2005 12:33:36 GMT
|
Grinder
Delphi Developer |
Sun, 15 May 2005 12:33:36 GMT
StdPicture = IPicture + IPictureDisp
Can anyone offer strategies for implementing a COM object that
supports IPicture and IPictureDisp interfaces? I can partially work it out, but cannot get type typelib rigged Thanks. |
Team
Delphi Developer |
Sun, 15 May 2005 15:48:41 GMT
Re:StdPicture = IPicture + IPictureDisp<<Grinder: Can anyone offer strategies for implementing a COM object that supports IPicture and IPictureDisp interfaces? Quoteworks with in-process servers /only/? It uses a Windows device handle, which is obviously invalid for other processes. -- TeamB don't see posts sent via Google or ISPs |
Grinde
Delphi Developer |
Sun, 15 May 2005 22:54:11 GMT
Re:StdPicture = IPicture + IPictureDisp"Deborah Pate (TeamB)" <d.p...@blueyonder.co.not-this-bit.uk> wrote in message news:VA.00001909.000c41f3@blueyonder.co.not-this-bit.uk... Quote> <<Grinder: ActiveX Library? I'm not sure how this affects use with DCOM -- at any rate, distributed use is not required. |
Grinde
Delphi Developer |
Mon, 16 May 2005 02:40:52 GMT
Re:StdPicture = IPicture + IPictureDisp"Deborah Pate (TeamB)" <d.p...@blueyonder.co.not-this-bit.uk> Quote> <<Grinder: |
Team
Delphi Developer |
Mon, 16 May 2005 03:07:44 GMT
Re:StdPicture = IPicture + IPictureDisp<<Grinder: Where does the implementation of IPicture go in this scenario? Quotewant your automation object to implement IPicture and IPictureDisp directly then you'll have to add IPicture to its declaration by hand. You could then use a TOleGraphic to implement its functions, perhaps. -- TeamB don't see posts sent via Google or ISPs |
Grinde
Delphi Developer |
Mon, 16 May 2005 03:20:41 GMT
Re:StdPicture = IPicture + IPictureDisp"Deborah Pate (TeamB)" <d.p...@blueyonder.co.not-this-bit.uk> Quote> <<Grinder: IPicture/IPictureDisp directly, as I want to implement IPicture. Can you outline the steps involved. This is my best attempt 1) Create new "ActiveX Library" project. At this point, I can build and register my library. In VB, I The snag comes in providing an implementation for IPictureDisp. |
Grinde
Delphi Developer |
Mon, 16 May 2005 03:26:08 GMT
Re:StdPicture = IPicture + IPictureDispQuote"Grinder" <grin...@no.spam.maam.com> wrote in message Quote
Can you elaborate on how to do this "by hand?" |
Team
Delphi Developer |
Mon, 16 May 2005 04:58:36 GMT
Re:StdPicture = IPicture + IPictureDisp<<Grinder: Is there some way to connect TAutoObject's IDispatch implementation with IPictureDisp's method and property definitions? Quote(mercifully only a subset of IPicture's) have to be described in the type library, with the appropriate dispids. I'm afraid you need to put them there yourself, using the type library editor. (Warning: I can't easily test this because in D7 the wizard-generated IPicture-implementing-object won't even compile. Implementing IPicture yourself is quite unusual.) Here are the methods and the dispids you need to include: -- TeamB don't see posts sent via Google or ISPs |
Grinde
Delphi Developer |
Mon, 16 May 2005 05:27:50 GMT
Re:StdPicture = IPicture + IPictureDisp"Deborah Pate (TeamB)" <d.p...@blueyonder.co.not-this-bit.uk> Quote> <<Grinder: defined, and how they are related. Something like this is where I'm at: classes: interfaces: dispinterfaces: How can I redefine this? (Warning: I can't easily Quote> test this because in D7 the wizard-generated IPicture and Picture. Quote
s/com/ctin_p_4gfk.asp |
Grinde
Delphi Developer |
Mon, 16 May 2005 11:04:23 GMT
Re:StdPicture = IPicture + IPictureDispThanks for your help, Deborah. Once I abandoned the TypeLib editor, I was able to work this out. |