Skip to main content
GameDev.net gamedev.net
🔒 Locked

Problem when exiting program

Started by WarMachine Sep 27, 2001 at 11:53 AM 6 replies 250+ views
Original Post
WarMachine
WarMachine
After running a program I made in DX8, when the program exits, there is left on the taskbar the gray rectangle with its title, and only when I click on it then it dissapears, how do I get tit to disappear when I exit the program? PS: Happens on all progrms I made using DX.
"You can get out of prison, but not out of the cemetery"
WarMachine
WarMachine
come on, no replies?
"You can get out of prison, but not out of the cemetery"
Dactylos
Dactylos
I have no idea what could be causing that, but I think it could very well be a Windows bug. I do quite often get a "dead" window button left in my taskbar after a program exits (though ususally without title, simply an empty grey box). And it''s not just my own programs that do this, e.g. Windows Media Player often do this, the standard Windows screensavers too... The list goes on...
Caramon
Caramon
Yeah that happens to me sometimes I dont thiink its related with your program.

I''ll meet you in the next life,where we can be together.
----------------------I'll meet you in the next life,where we can be together.
S1CA
S1CA
Make sure you:

a) DestroyWindow()
b) PostQuitMessage()
c) actually exit the message loop


If you miss any of those, you can get that problem. Simple test is to try one of the samples from the SDK - if they do it, its not your fault, if they don''t, it is and you should copy what they do.

--
Simon O''''Connor
Creative Asylum Ltd
www.creative-asylum.com
Simon O'Connor | Technical Director (Newcastle) Lockwood Publishing | LinkedIn | Personal site
UnshavenBastard
UnshavenBastard

Be sure to
->Release() all DX objects that you created
in reverse order of creation, before you exit the program.
Normally, any DX object that created other DX objects *should*
release these when destroyed, but maybe it''s a bug.

I had this problem, too. After I did what I just advised you,
everything went allright.


Promit
Promit
Im not sure sure _why_ the gray box appears, but it is a Windows internal problem and is not a big deal. Many apps cause it at some time or the other.

-----------------------------
The sad thing about artificial intelligence is that it lacks artifice and therefore intelligence.
SlimDX | Ventspace Blog | Twitter | Diverse teams make better games. I am currently hiring capable C++ engine developers in Baltimore, MD.

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.