LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Run time error UIR with Visual studio

I am unable to perform certain builds using Lab Windows CVI 8.1 and Visual Studio 2005.  What I've done is created the front panel using Lab Windows and integrated this with the backend in Visual Studio.

 

When I go to create a debug it build successfully.  Then I go to run it and get a pestky runtime error and the application aborts before it even starts.  Here's the error I get:

 

"Unable to start program 'c:\...\myexecutable.exe'

 

This application has failed to start because the application is incorrect.  Review the manifest file for possible errors.  Reinstalling the application may fix this problem.  For more details, please see the applicaiton event log."

 Could this be something with a CVI runtime dll?  I'm not sure how to correct it.  I've only seen it when trying to merge the Lab Windows and Visual Studio projects like explained.

 

Thanks!

 

0 Kudos
Message 1 of 4
(3,501 Views)
Did you include the call to InitCVIRTE? It is not required for CVI, but for external compilers...
0 Kudos
Message 2 of 4
(3,487 Views)

I do have the call to InitCVIRTE in my code.  The code snipit is shown below.  It's the first call I make.  Any other ideas??

 

Thanks! 

 

 

int APIENTRY _tWinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPTSTR lpCmdLine, int nCmdShow)

{

     ::InitCVIRTE(0, 0, 0);

     ...

}

0 Kudos
Message 3 of 4
(3,477 Views)
Since you mention that the issue doesn't manifest itself if you create the application in debug mode, I thought this article may be useful.
Warm regards,

pBerg
0 Kudos
Message 4 of 4
(3,452 Views)