使窗体上的关闭按钮失效
来源:岁月联盟
时间:2004-11-17
Const vbFormCode=1 'Unload method invoked from code
Const vbAppWindows=2 'Current Windows session ending
Const vbAppTaskManager=3 'Windows Task Manger is closing the application
Const vbFormMDIForm=4 'MDI child form is closing because the MDI form is closing
vbFormOwner=5 'The owner of the form is closing
Private Sub Form_QueryUnload(Cancel As Integer, UnloadMode As Integer)
If UnloadMode = vbFormControlMenu Then
Cancel = True
End If
End Sub
上一篇:只能对数值操作的TextBox
下一篇:XML 对象反序列化也动态编译?