03-03-2009 05:41 AM
Hi,
I'm using LabVIEW activex from visual c++ 6.0. My aim is to run a vi and get the result from some control from vi. I successfully done this.
Since labVIEW application launching and running is a time consuming task, I moved the code to a thread. Now when i create the instance of the application it returns NULL
#import "LabVIEW.tlb"
LabVIEW::_ApplicationPtr pLVApp;
pLVApp.CreateInstance("LabVIEW.Application");
This code works when it is called from the main thread, but from a worker thread it fails.
Am i missing something?