How to build a Windows tiny EXE

Post Reply
User avatar
Antonio Linares
Site Admin
Posts: 42508
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain
Has thanked: 30 times
Been thanked: 72 times
Contact:

How to build a Windows tiny EXE

Post by Antonio Linares »

hello.cpp

Code: Select all | Expand

#include <windows.h>

#pragma argsused

int WINAPI WinMain( HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nCmdShow )
{
   MessageBox( 0, "Hello world", "Information", MB_ICONINFORMATION );

   return 0;
}


To build it:
bcc32 -tW hello
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
Posts: 42508
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain
Has thanked: 30 times
Been thanked: 72 times
Contact:

Re: How to build a Windows tiny EXE

Post by Antonio Linares »

Ready for more C++ and Windows ? Then give FiveCpp a try ;-)

https://github.com/FiveTechSoft/FiveCpp

Code: Select all | Expand

#include "FiveCpp.h"

//----------------------------------------------------------------------------//

function Main()
{
   local oWnd = DefineWindow( "Hello world!" );

   oWnd.Activate();
}

//----------------------------------------------------------------------------//

https://github.com/FiveTechSoft/FiveCpp/blob/master/samples/tutor02.cpp
regards, saludos

Antonio Linares
www.fivetechsoft.com
Post Reply