This was an issue with a type library/com import -- and the events were
undeclared.
 
Ultimately I wrapped the type library in an component that exposed the
events.  It was not pretty, but I found a freeware tool that generated
the wrapper all on it's own.
 


________________________________

From: advanced_delphi@yahoogroups.com
[mailto:advanced_del...@yahoogroups.com] On Behalf Of mikcaau
Sent: Monday, June 22, 2009 8:04 PM
To: advanced_delphi@yahoogroups.com
Subject: [advanced_delphi] Re: Replacing VB's "WithEvents" in Delphi?





Dave,
Which event do you want to monitor?
Delphi has many events and if the one you want is not there then you can
create a new object, intercept the messages that notify the event change
and then fire your own events.

Mick

Mick

--- In advanced_delphi@yahoogroups.com
<mailto:advanced_delphi%40yahoogroups.com> , "David Wright"
<dwri...@...> wrote:
>
> Hi All,
> 
> I have been digging through google and have not been able to find a
> workaround, but I did find a few claims that there is not equivelant
to
> WithEvents in Delphi.
> 
> Is this still true?
> 
> Here is a snippet of VB code I want to convert:
> Private WithEvents myPS autECLPS
> 
> The entire rest of the API I am working with uses standard events
> processing, but this one last bit it crucial. I would hate to port
> everything to VB this point. My current workaround involves using a
> timer to keep checking for updates, but I would prefer to make this
> event driven instead. Currenltly I can turn on the event, but I cannot
> point it to an actual procedure :(
> 
> Thanks for any thoughts,
> Dave
>




Reply via email to