Click here to Skip to main content
15,891,708 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
I get a link error 1104 (and 1181) where it can't find a LIB file. I have no references in VS2005 settings that mention the LIB file. And I don't want to use that file so I don't want to set a path so that it finds it.

How does the linker even know the file name to look for. I've looked at all the project properties, etc. I've performed a text search in the project and the entire computer without success.
Posted

1. Look for a
C++
#pragma comment(lib, "xyz")
in your C / C++ source where xyz is the library name.

2. as a sanity check, open the project and solution files in a text editor and search for the library name.
 
Share this answer
 
Click on Project->Properties menu item and then , on the newly appeared dialog select the Configuration Properties->VC++ Directories node. On the right, you may find the list of the .LIB search paths (Library Directories).

Quote:
And I don't want to use that file so I don't want to set a path so that it finds it.
You have to be sure you know what are you doing. Any executable needs DLLs and LIB files are required by the linker in order to build an application able to load correctly the DLLs at runtime.
 
Share this answer
 
The suggestion from bling pointed me to the solution. I am using third party controls. They dynamically created the #pragma comment statement in one of their header files. Based upon the projects compile settings, it created a library name and looked for it.

Thanks BLING
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900