LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

DLL CALLBACK EVENT IN LABVIEW

I am developing application using Labview 7.
LabVIEW application is invoking VC++ dll.

Is it possible in LabVIEW to get callback event from VC++ dll into LabVIEW application with some data like string ?
0 Kudos
Message 1 of 4
(5,463 Views)
Hello

I am not sure if this helps, but did you consider ActiveX callbacks? ActiveX can be written in VC++ and LV can read a callback from it.

cheers
Pawel
0 Kudos
Message 2 of 4
(5,439 Views)
I'm not sure that I completely understand your question, but it sounds like you are trying to take events from a DLL and pass them into LabVIEW. I've attached an example that does just this. Here is a brief description:

This example demonstrates how to post a message to the LabVIEW event structure from a DLL and how to pass it data as well (using the PostLVUserEvent() function). The VI calls the dll, which in turn passes 3 messages to the event structure. The data ( in this case, a LabVIEW string ) is displayed in a dialog window that stays open for 2 seconds. The dll is called in its own thread so it does not hang the UI thread. Refer to the "Using External Code in LabVIEW" manual for more information about the function.

The example was developed in LabVIEW 7.0 and the DLL in VC++ 6.0. Hopefully, this example gives you a good start!

Regards,

AE Sulzer
Applications Engineer
National Instruments
E. Sulzer
Applications Engineer
National Instruments
Message 3 of 4
(5,424 Views)
Whoops! Here is the attachment...

AE Sulzer
Applications Engineer
National Instruments
E. Sulzer
Applications Engineer
National Instruments
0 Kudos
Message 4 of 4
(5,423 Views)