Measurement Studio for VC++

cancel
Showing results for 
Search instead for 
Did you mean: 

LNK2019 unresolved external symbol error

mfc18 error LNK2019: unresolved external symbol "class std::auto_ptr<class NI::CniDemo> NI::global_demo" (?global_demo@NI@@3V?$auto_ptr@VCniDemo@NI@@@std@@A) referenced in function "public: static enum NI::MathError __cdecl NI::CNiMath::FFT(class NI::CNiComplexVector<double> &)" (?FFT@CNiMath@NI@@SA?AW4MathError@2@AAV?$CNiComplexVector@N@2@@Z)
 
I used to compile and execute samples of measurement studio. I uninstalled and re-installed measuremet srudio and now I get the error above. whenever I try to use CNIMath library I get this error. But I can draw graphs so there is no problem with other libraries. what might be the problem
thanks
 
( using measurement studio 7.0 with vs2003 in a mfc project)
0 Kudos
Message 1 of 5
(11,120 Views)
It is strange that you are able to get some of the Measurement Studio functions working but not the Math functions.  We can check to see which library directories are setup for your Visual Studio environment.  From Visual Studio 2003 goto Tools -> Options...  Select the Projects -> VC++ Directories.  Choose Show directories for Library files.  Make sure that you have the following directories listed:

C:\Program Files\National Instruments\MeasurementStudioVS2003\VCNET\Instr
C:\Program Files\National Instruments\MeasurementStudioVS2003\VCNET\Lib

If they are listed, you may try changing the order.  Make sure that Instr is higher than Lib in the list.

Let me know if this fixes your issue.

Thanks,

Tyler Tigue
NI


0 Kudos
Message 2 of 5
(11,080 Views)
yeah I checked it but it was set as you said. another interesting thing is I can access "pi" variable in math library. ex:

double a= NI :: CNiMath :: Pi;



but when I use

NI::CNiMath::FFT(fftData,imgData);



I get these errors



mfc3 error LNK2019: unresolved external symbol "public: int __thiscall NI::CniDemo::Access(void)" (?Access@CniDemo@NI@@QAEHXZ) referenced in function "public: static enum NI::MathError __cdecl NI::CNiMath::FFT(class NI::CNiComplexVector &)" (?FFT@CNiMath@NI@@SA?AW4MathError@2@AAV?$CNiComplexVector@N@2@@Z)



mfc3 error LNK2019: unresolved external symbol "class std::auto_ptr NI::global_demo" (?global_demo@NI@@3V?$auto_ptr@VCniDemo@NI@@@std@@A) referenced in function "public: static enum NI::MathError __cdecl NI::CNiMath::FFT(class NI::CNiComplexVector &)" (?FFT@CNiMath@NI@@SA?AW4MathError@2@AAV?$CNiComplexVector@N@2@@Z)

Message Edited by alperkal on 12-16-2005 06:00 AM

0 Kudos
Message 3 of 5
(11,069 Views)
maybe these give more information.

Linking...
NiMath71D.lib(FrequencyDomain.obj) : error LNK2019: unresolved external symbol "public: int __thiscall NI::CniDemo::Access(void)" (?Access@CniDemo@NI@@QAEHXZ) referenced in function "public: static enum NI::MathError __cdecl NI::CNiMath::FFT(class NI::CNiComplexVector &)" (?FFT@CNiMath@NI@@SA?AW4MathError@2@AAV?$CNiComplexVector@N@2@@Z)


NiMath71D.lib(FrequencyDomain.obj) : error LNK2019: unresolved external symbol "class std::auto_ptr NI::global_demo" (?global_demo@NI@@3V?$auto_ptr@VCniDemo@NI@@@std@@A) referenced in function "public: static enum NI::MathError __cdecl NI::CNiMath::FFT(class NI::CNiComplexVector &)" (?FFT@CNiMath@NI@@SA?AW4MathError@2@AAV?$CNiComplexVector@N@2@@Z)
Debug/mfc3.exe : fatal error LNK1120: 2 unresolved externals
0 Kudos
Message 4 of 5
(11,061 Views)
It appears that you are missing the file that describes the CNiDemo namespace.  Your installation may have been corrupted in some way.  Can you try reinserting the disk and repairing the installation.  To repair an installation, go to Add/Remove Programs and select to modify the Measurement Studio installation.  It should point to an id file on the disk that will go through the repairing process.

Regards,

Tyler T
0 Kudos
Message 5 of 5
(10,990 Views)