error LNK2019

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • sandeepkavade
    New Member
    • Mar 2007
    • 30

    error LNK2019

    i am trying to test a app. while _UNICODE defined. but when i define _UNICODE
    in the app. it gives me following error.

    Unicode_Test error LNK2019: unresolved external symbol _WinMain@16 referenced in function _WinMainCRTStar tup

    i have included all necessary libraries. where i am going wrong?

    Thanx in advance.
  • svlsr2000
    Recognized Expert New Member
    • Feb 2007
    • 181

    #2
    could You please post your code or part of your code which is causing the problem.

    Comment

    • gpraghuram
      Recognized Expert Top Contributor
      • Mar 2007
      • 1275

      #3
      HI,
      Usually u will get the winmain error when you try to build a executable for a cpp file without main in it.
      Check whether you have a main or if u are trying to build a executable.
      Thanks
      Raghuram

      Comment

      • Banfa
        Recognized Expert Expert
        • Feb 2006
        • 9067

        #4
        Actually I am guessing that you program has a main in it.

        WinMain is the entry point for a Windows program, my guess is you have somehow told the linker that it is linking a Windows program when it is actually linking a console program and so it has ended up looking for the WinMain entry point which is not in your program and has caused the error.

        Comment

        Working...