Jump to content

  • Log In with Google      Sign In   
  • Create Account


#ActualSalami

Posted 01 May 2013 - 10:09 AM

#include <windows.h>
int WINAPI winMain(HINSTANCE hInstance,HINSTANCE hPrevInstance,LPSTR lpCmdLine,int nShowCmd)
{
    MessageBox(NULL,L"Some text",L"Info",MB_OKCANCEL | MB_ICONINFORMATION);

    return 0;
}

Error    1    error LNK2019: unresolved external symbol _WinMain@16 referenced in function ___tmainCRTStartup    C:\Bob\Projects\Part1\Part1\MSVCRTD.lib(crtexew.obj)    Part1


#6Salami

Posted 01 May 2013 - 10:09 AM

#include <windows.h>
int WINAPI winMain(HINSTANCE hInstance,HINSTANCE hPrevInstance,LPSTR lpCmdLine,int nShowCmd)
{
    MessageBox(NULL,L"Some text",L"Info",MB_OKCANCEL | MB_ICONINFORMATION);

    return 0;
}

Error    1    error LNK2019: unresolved external symbol _WinMain@16 referenced in function ___tmainCRTStartup    C:\Bob\Projects\Part1\Part1\MSVCRTD.lib(crtexew.obj)    Part1


#5Salami

Posted 01 May 2013 - 10:08 AM

#include <windows.h>
int WINAPI winMain(HINSTANCE hInstance,HINSTANCE hPrevInstance,LPSTR lpCmdLine,int nShowCmd)
{
    MessageBox(NULL,L"Some text",L"Info",MB_OKCANCEL | MB_ICONINFORMATION);

    return 0;
}

Error    1    error LNK2019: unresolved external symbol _WinMain@16 referenced in function ___tmainCRTStartup    C:\Bob\Projects\Part1\Part1\MSVCRTD.lib(crtexew.obj)    Part1


#4Salami

Posted 01 May 2013 - 10:05 AM

nill


#3rip-off

Posted 24 April 2013 - 11:47 AM

ey guys,

 

I'm trying to squeeze some useful information out of ancient tutorials on the net but I'm stuck at the starting stage since I never used any of the Visual Studio IDEs.

 

I downloaded and Installed Visual Studio 2012 for Desktop, told that it contains DirectX 11 (within some Windows 8 SDK).

 

Right after, I made a Win32 Project with "empty Project" option as in one of "those ancient tutorials". Typed some code below:

#include <windows.h>



int WINAPI winMain(HINSTANCE hInstance,HINSTANCE hPrevInstance,LPSTR lpCmdLine,int nShowCmd)

{

    MessageBox(NULL,L"Some text",L"Info",MB_OKCANCEL | MB_ICONINFORMATION);



    return 0;

}

 

More sadly than funny, I'm not even sure how to compile, so I mash the "Build Solution" option under "BUILD ->" in the IDE (just because it worked for simple c++ program which I found to be lying in a Debug folder after that) aaaand.... it cried about some reference:

Error    1    error LNK2019: unresolved external symbol _WinMain@16 referenced in function ___tmainCRTStartup    C:\Bob\Projects\Part1\Part1\MSVCRTD.lib(crtexew.obj)    Part1



Error    2    error LNK1120: 1 unresolved externals    C:\Bob\Projects\Part1\Debug\Part1.exe    Part1

 

I can only assume that I was supposed to configure something somewhere somehow to make that embedded DirectX work... I don't even know where it is supposed to be looking at the Program Files of Visual Studio 2012.

 

Help passing this extremely annoying yet blocking beginner problem would be appreciated.


#2Salami

Posted 24 April 2013 - 07:20 AM

nill


PARTNERS