Phil,

You cannot share a DC between different processes - because they are in
different address space.  However, you can try to FindWindow to look for the
window handle, and obtain a DC to paint on its surface.

The other suggestion is to use an in-process (ie Active-X DLL) server.

Dennis.

----- Original Message -----
From: "Phil Middlemiss" <[EMAIL PROTECTED]>
To: "Multiple recipients of list delphi" <[EMAIL PROTECTED]>
Sent: Wednesday, September 17, 2003 1:16 PM
Subject: [DUG]: Sharing a drawing surface


> Apologies if you get this twice but I think our mail server swallowed it
the
> first time I sent it:
>
> Does anyone know how to share a device context for drawing between
separate
> programs? Is it possible at all? I have tried passing the handle to the
> context using an ActiveX connection so that a separate program can
annotate
> an image but even though the correct handle value is passed, none of the
> annotation code seems to have any effect (the drawing code itself works
> fine - I've tested that separately).
>
>
> Any help would be appreciated.
>
> Cheers,
> Phil.
>
> --------------------------------------------------------------------------
-
>     New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
>                   Website: http://www.delphi.org.nz
> To UnSub, send email to: [EMAIL PROTECTED]
> with body of "unsubscribe delphi"
> Web Archive at: http://www.mail-archive.com/delphi%40delphi.org.nz/
>
---------------------------------------------------------------------------
    New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
                  Website: http://www.delphi.org.nz
To UnSub, send email to: [EMAIL PROTECTED] 
with body of "unsubscribe delphi"
Web Archive at: http://www.mail-archive.com/delphi%40delphi.org.nz/

Reply via email to