user451498
user451498

Reputation:

Getting rid of the command prompt window in win32

I just built a standard win32 applicaion but when I run it, there is a command prompt

how can I get rid of that cmd window?

I am not using an IDE I am just using notepad++ to edit

and mingw to compile through the command prompt

I am doing the g++ command to compile

should I use a different one?

thanks

Upvotes: 3

Views: 529

Answers (2)

bumbobway
bumbobway

Reputation: 616

Make sure you have WinMain as your entry point.

See this basic article in MSDN: http://msdn.microsoft.com/en-us/library/ff381406(VS.85).aspx

This follow up link is also helpful: http://msdn.microsoft.com/en-us/library/ff381409(v=VS.85).aspx

Upvotes: 1

Kos
Kos

Reputation: 72299

Try adding -mwindows to your linker flags.

Upvotes: 5

Related Questions