LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Help with code interface node!

Hi,

I'm trying to convert a C++ code into a LabVIEW CIN. I went through all the steps that are listed in "How to build a CIN code resorce (.lsb file)" in external code manual, but I still get the following errors:

--------------------Configuration: NDPLabVIEW - Win32 Debug--------------------
Linking...
Creating library Debug/NDPLabVIEW.lib and object Debug/NDPLabVIEW.exp
nafxcwd.lib(appcore.obj) : error LNK2001: unresolved external symbol ___argv
nafxcwd.lib(appcore.obj) : error LNK2001: unresolved external symbol ___argc
nafxcwd.lib(timecore.obj) : error LNK2001: unresolved external symbol __mbctype
nafxcwd.lib(filelist.obj) : error LNK2001: unresolved external symbol __mbctype
nafxcwd.lib(apphelp.obj) : error LNK200
1: unresolved external symbol __mbctype
Debug/NDPLabVIEW.dll : fatal error LNK1120: 3 unresolved externals
Error executing link.exe.

NDPLabVIEW.dll - 6 error(s), 0 warning(s)
-----------------------------------------------------
The compiler doesn't give any errors, it compiles successfully.

I'm using VC++ 6.0 and all the required adjustments are done for workspace configuration according to the external code manual.

One more thing: The manual says "extcode.h" must be the first #include followed by "hosttype.h". However, the code I'm working on includes "stdafx.h", and when I #include "extcode.h" and "hosttype.h" first, the code doesn't even compile.

Attached is the source code.

Thanks,

Sacit M. Cetiner
Breazeale Nuclear Reactor
0 Kudos
Message 1 of 3
(3,031 Views)
Attached is a response I got from Tech Support at NI regarding the creation of code interface nodes with LabVIEW 6.0 and Visual C++ 6.0. I was unable to create CINs until I implemented the changes specified. I hope this helps.

If not, at least it will point you to someone at NI who I found to be an excellent resource.
0 Kudos
Message 2 of 3
(3,031 Views)
Overall, it looks like you are having trouble linking to the nafxcwd.lib. It looks like you need to define the variables that are being looked for and it should resolve the issue. Also, you might look at compiling a dll and calling it from LabVIEW instead of using the CIN - the dll is really the way to go.
0 Kudos
Message 3 of 3
(3,031 Views)