LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

How to transfer data between CVI & VC++ applications?

Hello!

I use CVI.exe as a automation server in my VC project.I run myPrj.prj from VC,and want to control it's running state. So I need to transfer data(integer or char array) between cvi & vc.

For the time being,I use Windows API Function ::BroadcastSystemMessage() to send message from myPrj to VC.But as we all know, it sends message to every application window.I am not very satisfied with this method.
Is there any other solution?
What's more,I don't know how to receive windows message in cvi from vc.

Thanks!
0 Kudos
Message 1 of 2
(2,955 Views)
Lily,

I think I provided a solution to the BroadcastSystemMessage() approach in my answer to your other question regarding "Sending Char Array from CVI to VC".. (My answer will be dated 7/3/2001). You can get away with only using the Broadcast message 'once' (from each process) as long as you pass the Window Handle (of the calling process) to the receiving process on the first transmission. By capturing this data (passed in the wparam field) -and by using WinTools drivers (search the NI site - but you might run into a web page fault (see below)) you can then send 'any' message to the targeted window handles (as long as wparam and lparam data is of type integer).

Regarding WinTools. Search NI for WinTools and follow the link. I consistently ran into a Web Page fau
lt, but using Internet Explorer I could still page down and find the WinTools.zip file for download.

drbarbour@certtech.com
0 Kudos
Message 2 of 2
(2,955 Views)