Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Default to NO with messagebox
Message
From
08/01/2003 19:21:55
 
General information
Forum:
Visual Basic
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00738010
Message ID:
00739636
Views:
8
Hi, it's me again, I sent you a response, still dun know if it where useful, so I am sending you an snipped of code, that is, without a doubt, more useful.

'Add a single executable form and add this code to the unload event of it
'it's quite simple, but very effective, the constant value that I use
'for set the "no" button as default is 256, that number makes it all!!!
'Hope this can help you!!!!., I can send you the rest of values
'for 2 or 3 buttons your pal => Alvison Hunter Arnuero

Option Explicit

Private Sub Form_QueryUnload(Cancel As Integer, UnloadMode As Integer)
If MsgBox("It is seems like ya wanna leave this section:" & _
Chr(13) & "Do ya Really wanna close this Window?", _
vbYesNo + vbQuestion + 256, "Hey man? what is wrong with ya?") = vbYes Then
Unload Me
Else
Cancel = True
Exit Sub
End If
End Sub
Previous
Reply
Map
View

Click here to load this message in the networking platform