LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

how can i use a dll created in visual c++ in labwindows/cvi?

i have written a dll in visual c++.when i use it in labwindows/cvi5.01,errors shows:project link erros,bad header encoutered while reading external model.How can i do?
0 Kudos
Message 1 of 2
(3,060 Views)
You need to specify the Visual C++ 6.0 link option "/LINK50COMPAT" to generate an import library compatible with Visual C++ 5.0, and therefore LabWindows/CVI.

To change the link options in Visual C++ 6.0, do the following:

1. Go to Project » Settings » Link Tab.

2. In the link options box type /LINK50COMPAT


Alternatively, use CVI to open a header file that prototypes all of the functions exported from the DLL, and then select CVI's Options » Generate DLL Import Library to generate a *.lib file that you can successfully link in your project.

NOTE: You can load the Visual C++ generated DLL and get the functions yourself, by using LoadLibrary, GetProcAddress and so on.

NOTE: LabWindows/CVI 5.5 and above does support Visual C++ 6.0 library format.
J.R. Allen
Message 2 of 2
(3,060 Views)