Board index » delphi » Active X object in an automation object

Active X object in an automation object

I created an executable in MSVC (sorry...) that uses a
National Instruments CWSerial Active X Component.

I then exposed some of the methods as automation methods.

When I run the MSVC application standalone, accessing the
serial components works fine.

However, my ultimate desire is to incorporate the type library
create by VC into a delphi project.  At this time I have completed
this task.  My delphi app can access the automation methods of
the VC program that do not access the serial active X component.
However, when I try to access a method that uses the active x component,

I get the message "the server threw an exception".

Would anyone have any insight as to why I can run the VC application
stand alone (I am assuming this means the serial component finds all
its associated files).  However, I cannot access the methods that use
the
Active X serial component.

Many thanks in advance,
Mark Everly

 

Re:Active X object in an automation object


I would first try to simulate the Delphi method call by calling the same
exact method from within the C++ app through a button click or something. If
that works, then I would debug the C++ server (with the Delphi client
calling into it) by putting a breakpoint at the start of the offending
method call and then tracing into it and locating where the server exception
is thrown. Most likely, it's possible that there's a memory
corruption/violation error in the method code.

have fun
--
Binh Ly
http://www.techvanguards.com

Quote
"Mark Everly" <m...@ace-comp.com> wrote in message

news:3A5DD8D6.44FCB81@ace-comp.com...
Quote
> I created an executable in MSVC (sorry...) that uses a
> National Instruments CWSerial Active X Component.

> I then exposed some of the methods as automation methods.

> When I run the MSVC application standalone, accessing the
> serial components works fine.

> However, my ultimate desire is to incorporate the type library
> create by VC into a delphi project.  At this time I have completed
> this task.  My delphi app can access the automation methods of
> the VC program that do not access the serial active X component.
> However, when I try to access a method that uses the active x component,

> I get the message "the server threw an exception".

> Would anyone have any insight as to why I can run the VC application
> stand alone (I am assuming this means the serial component finds all
> its associated files).  However, I cannot access the methods that use
> the
> Active X serial component.

> Many thanks in advance,
> Mark Everly

Other Threads