Cant destroy the modeless dlg by itself using "delete this"
I'm using WTL for UI dev.
Here is my sample code.
I just created a modeless About dlg and want to destroy it but failed!
This About dlg contians a CBitmapButton.
Can anyone give me a hand?
Visual Studio .Net 2003, VC++7.1
BTW: the About dlg must be destroy/delete by itself!!
[329 byte] By [
shaohao] at [2007-11-19 19:32:42]

# 1 Re: Cant destroy the modeless dlg by itself using "delete this"
See this ( http://www.dev-archive.com/forum/showthread.php?t=377011).
logan at 2007-11-10 23:43:28 >

# 3 Re: Cant destroy the modeless dlg by itself using "delete this"
THX, but it's no useful.
I've found that it keep crashing if I destroyed it by clicking a CBitmapButton. But everyting goes OK if I destroyed it by clicking a normal button.
# 4 Re: Cant destroy the modeless dlg by itself using "delete this"
See Step by Step debugging ( http://www.dev-archive.com/forum/showthread.php?t=360659).
cilu at 2007-11-10 23:46:29 >

# 5 Re: Cant destroy the modeless dlg by itself using "delete this"
Did anyone try my test code ?
myWTL.zip ( http://www.dev-archive.com/forum/attachment.php?attachmentid=14756)
Can you give me a hand?