Unresolved external symbol errors without #pragma comment lib command
问题 I added a project to my VS2008 solution and set a dependency to this newly added project in my startup project via the project settings window. The problem was that I had unresolved external symbol errors all over the place, but once I wrote the line #pragma comment (lib, "path_to/my_lib.lib") inside the file using the functions of my library, everything worked just fine. Specifically, I added that line right after my include #include "path_to/my_lib.h" #pragma comment (lib, "path_to/my_lib