|
-
Feb 28th, 2002, 10:43 AM
#1
Thread Starter
Frenzied Member
*** RESOLVED *** MDI Form blanks out !!
I have the following code in the Unload event of my MDI Master form :
VB Code:
Private Sub MDIForm_Unload(Cancel As Integer)
Quit = MsgBox("Are you sure you want to Quit ?", vbYesNo, "Confirm Quit")
If Quit = vbYes Then
Screen.MousePointer = vbHourglass
RecordTimeOff
Screen.MousePointer = vbNormal
HtmlHelp Me.hwnd, "", HH_CLOSE_ALL, ""
End
Else
Cancel = True
Exit Sub
End If
End Sub
The problem I have is that before I get the Msgbox on screen, my MDI form is blanked so all I see is a white background !!
Really handy if the user says no !!!!
Any ideas anyone ?
Last edited by TheBionicOrange; Feb 28th, 2002 at 11:37 AM.
-
Feb 28th, 2002, 10:54 AM
#2
maybe throw in a doevents??
-
Feb 28th, 2002, 11:07 AM
#3
Lively Member
Maybe don't do an END
END really NEVER should be used. Take it out and let the interface do the proper QueryUnload events and etc.
The END statement can prevent the proper unloading and release of memory.
-
Feb 28th, 2002, 11:30 AM
#4
Thread Starter
Frenzied Member
OK I took the END out (good point !), and I've tried DoEvents in various places ..... but still blanking form !!!!
Any more ideas anyone ?
-
Feb 28th, 2002, 11:36 AM
#5
Thread Starter
Frenzied Member
Excuse the stooopidness
Got it now
-
Feb 28th, 2002, 11:37 AM
#6
Lively Member
QueryUnload
Remember that QueryUnload event I talked about....do your MSGBOX there. And use the cancel there. It happens before the unloads
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|