I came across a piece of code which uses #pragma comment(lib, \"libraryname\").
Why this type of usage as opposed to just linking the library from the properties men
Classic example - linking against different versions of the library:
#if CURRENT_VERSION >= 10 #pragma comment(lib, "thirdPartyLibV2.0.lib") #else //version < 10 #pragma comment(lib, "thirdPartyLibV1.0.lib") #endif