News:

Download Pelles C here: http://www.pellesc.se

Main Menu

Very small C run-time startup module

Started by Vortex, Yesterday at 07:16:13 PM

Previous topic - Next topic

Vortex

Here is an example of a very small C run-time startup module if command line parameters can be omitted.

#include <windows.h>

extern int __stdcall WinMain(HINSTANCE hInstance,HINSTANCE hPrevInstance,LPSTR lpCmdLine,int nShowCmd);

int __cdecl WinMainCRTStartup(void)

{
    ExitProcess(WinMain(GetModuleHandle(NULL),NULL,NULL,SW_SHOWDEFAULT));
}

Code it... That's all...