LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

How to register a activex call back event in lab windows?

How  to register a activex call back event in lab windows? Please let me know. Thank you.
0 Kudos
Message 1 of 2
(3,116 Views)

HI amicshah,

You can use the ActiveX Controller Wizard (Tools >> Create ActiveX Controller...) to generate a new instrument driver (essentially a wrapper) for an ActiveX server. This instrument driver contains functions to instantiate the server's object, reference existing server objects, get/set the object's properties, and call the object's methods. 

As you know, ActiveX servers specify the events they generate as a collection of methods in an event object. For each event object you select, the wizard generates a set of functions you can use to register callbacks for each event. LabWindows/CVI calls the callbacks when the server generates the events.  After you use this wizard, you will notice in your newly creaed instrument driver, a class called "Event Callback Registration Functions". You use those functions to specify the callback functon that gets fired on that event.

You can also check out the low-level ActiveX functions in the Library Tree under Libraries >> ActiveX Library >> Low-Level Functions >> Events.

Hope this helps!

Best Regards,

Jonathan N.
National Instruments
0 Kudos
Message 2 of 2
(3,103 Views)