Jump to content


msvcrt.lib error!(in VS2005)


  • You cannot reply to this topic
4 replies to this topic

#1 XiiX

    New Member

  • Members
  • Pip
  • 7 posts

Posted 06 May 2009 - 04:20 PM

Hi.I would like to ask if someone knows how to fix this problem?
I am working on VS2005 and i cant build my project,i am just getting this error

msvcrt.lib(crtexe.obj) : error LNK2001: unresolved external symbol _main
1>C:\Users\XiiX\Desktop\Racing-Sense\RacingSense\Release \RacingSense.exe : fatal error LNK1120: 1 unresolved externals

Please help me if you can!!!
Thanks!

#2 Reedbeta

    DevMaster Staff

  • Administrators
  • 4969 posts
  • LocationBellevue, WA

Posted 06 May 2009 - 05:00 PM

It means the linker is trying to find the 'main' function, but there isn't one. Probably, the file it's in is not being included in the project.
reedbeta.com - developer blog, OpenGL demos, and other projects

#3 XiiX

    New Member

  • Members
  • Pip
  • 7 posts

Posted 06 May 2009 - 05:08 PM

Ok Thanks, but what file i need to include becose i allready included in project "msvcrt.lib" file.

#4 Reedbeta

    DevMaster Staff

  • Administrators
  • 4969 posts
  • LocationBellevue, WA

Posted 06 May 2009 - 05:52 PM

You need to write a main function, in a cpp file, and include that in the project. If you don't know what a main function is, you need to go get a book about C/C++ before going any further.

You don't need to include msvcrt.lib in your project; it's automatically included.
reedbeta.com - developer blog, OpenGL demos, and other projects

#5 XiiX

    New Member

  • Members
  • Pip
  • 7 posts

Posted 06 May 2009 - 06:10 PM

Okay i founded my problem.Engine i am using don't work in console application only in Win32 basic app.I writed main function and it worked.

THANKS FOR HELP!





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users