I am writing a test program. I am trying to do simple visa calls to instruments on USB. I cannot get the program to link – unresolved externals. At this point, my program is very simple, only a couple visa calls. I have read some content about similar problems and have tried what was suggested with out any luck.
I am using MS VisualStudio 19. I have entered the visa.h folder as C/C++ Additional Include Directory. The linker can’t find any of the contained functions, such as ViOpen(). NI IVI is installed on my PC and I have added the lib folder to the VS Linker Additional Library Directories. I have also entered all the .lib files in that folder to the Linker\Input\Additional Dependencies field. But when I compile and link, I get Unresolved External Symbol errors for all the visa functions.
Folder on my PC with the lib files (there are 4 files) is…
C:\Program Files\IVI Foundation\VISA\Win64\Lib_x64\msc.
Folder on my PC with visa.h is…
C:\Program Files\IVI Foundation\VISA\Win64\Include.
Any ideas will be much appreciated.
Leave an answer