I just recently bought some hardware that came with a header file and object file library (The hardware is NI USB-6008 DAQ Card). I want to link the library to my current project in visual C++. I have included the header file, but how do I link the library that came with the hardware to the project?
Thanks!
I am going to assume you are using Visual Studio and the library has come compiled already. Right click your program under solution explorer, select properties and under the Configuration Properties, select Linker then Input. You should see a field called Additional Dependencies in which you can add the
You can also link in the source files (only Visual Studio can do this as far as I am aware) by typing
.aor.libfile. The settings look like the below.#pragma comment (lib, "yourlibraryfilehere.lib")This method only works if the.aor.libfile is in Visual Studio’s/lib/directory.