Link to home
Start Free TrialLog in
Avatar of matthewsmith
matthewsmith

asked on

AllocConsole() question

Hi, is it possible to hide the console window that pops up when you make a call to AllocConsole?  Thanks.

-Matt
ASKER CERTIFIED SOLUTION
Avatar of alechko
alechko

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of matthewsmith
matthewsmith

ASKER

I could use ShowWindow() to hide the console window if I had a handle to the console, but how would I get the handle?

-Matt
Obtaining a Console Window Handle (HWND)
Article ID: Q124103
If I'm not wrong, you have to wait (Sleep) some time between AllocConsole() and attempt to find the console window.
Thanks for the help all.  It's kind of annoying to have the console window flash when starting up the gui app, but hey, it works.  Thanks again. :)