Error LNK2005: _DllMain@12 already defined


I'm trying to add a dialog box to an existing dl that doesn't have any. When I do, I get "error LNK2005: _DllMain@12 already defined". I've read that I need to delete the existing DLLMain in my project to get rid of the error. After deleting it, I get error "LNK1149: output filename matches input filename...."

How to I get this to work?
apostrophe27Asked:
Who is Participating?

[Webinar] Streamline your web hosting managementRegister Today

x
 
apostrophe27Connect With a Mentor Author Commented:
I started a new dll project, added my existing code to it, and it works now. I don't know what's different from my original project.

Thanks for trying to help me.
0
 
Subrat (C++ windows/Linux)Software EngineerCommented:
If ur using MFC and CRT functions, then plz have a look on following link.
http://support.microsoft.com/kb/148652
0
 
sureshmunugotiCommented:
To get resolve this linker error, use the #pragma comment(lib,"YourLibfile.lib")
or you need to change the out put path of you library.
0
All Courses

From novice to tech pro — start learning today.