WinMain ???

  • Thread starter Thread starter Lloyd Dupont
  • Start date Start date
L

Lloyd Dupont

I don't understand !!!!!!

Sometimes VS.NET seems to compile fine with a "int main(int, char*)"
function
sometimes not...

worst recently I had a project which (for some reasons) didn't like "main()"
startup function and, copying from a similar project, I use the following
entry point:

int APIENTRY _tWinMain(HINSTANCE, HINSTANCE, LPTSTR, int);

It works fine for a while then I played a bit with the project property
(just adding a new library and header include path and a new library) and
suddenly the project didn't link any longer complaining WinMain@16 is
missing !

what the hell is that !!??!!
 
Lloyd said:
I don't understand !!!!!!

Sometimes VS.NET seems to compile fine with a "int main(int, char*)"
function
sometimes not...

worst recently I had a project which (for some reasons) didn't like "main()"
startup function and, copying from a similar project, I use the following
entry point:

int APIENTRY _tWinMain(HINSTANCE, HINSTANCE, LPTSTR, int);

It works fine for a while then I played a bit with the project property
(just adding a new library and header include path and a new library) and
suddenly the project didn't link any longer complaining WinMain@16 is
missing !

what the hell is that !!??!!

Console apps get "int main(int, char *[])";
Win32 GUI Apps get "int APIENTRY WinMain(HINSTANCE, HINSTANCE, LPTSTR, int)"
 
thanks, I found it !

red floyd said:
Lloyd said:
I don't understand !!!!!!

Sometimes VS.NET seems to compile fine with a "int main(int, char*)"
function
sometimes not...

worst recently I had a project which (for some reasons) didn't like "main()"
startup function and, copying from a similar project, I use the following
entry point:

int APIENTRY _tWinMain(HINSTANCE, HINSTANCE, LPTSTR, int);

It works fine for a while then I played a bit with the project property
(just adding a new library and header include path and a new library) and
suddenly the project didn't link any longer complaining WinMain@16 is
missing !

what the hell is that !!??!!

Console apps get "int main(int, char *[])";
Win32 GUI Apps get "int APIENTRY WinMain(HINSTANCE, HINSTANCE, LPTSTR, int)"
 
Back
Top