|
|
|||||||||
|
|||||||||
|
|||||||||
| |
||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Executing Code on Visual Basic Exit
Hi,
I am writing a program in visual basic 6. I need to be able to execute some code whenever the user closes the program. (Clicks on the 'x' in the top right hand corner or press' alt-f4 etc... How do I go about capturing that event? Thanks ![]() |
|
#2
|
|||
|
|||
|
Quote:
Private Sub Form_Terminate() msgbox "Terminate" End Sub or Private Sub Form_Unload() msgbox "Unload" End Sub I am not sure |
|
#3
|
|||
|
|||
|
Thanks. I think Form_Terminate() should do the trick
![]() |
![]() |
| Viewing: ASP Free Forums > Programming > Visual Basic Programming > Executing Code on Visual Basic Exit |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|