G
Guest
There is a program in VB , in which, there is a
Form_QueryUnload( Cancel as Integer, UnloadMode as Integer)
which would be called when the form is being closed. The UnloadMode is used to find out if the Fomr is being closed by the user - in which case this event is to be cancelled - and if it is coming from within the application, then it would close the application.
In .NET, the equivalent Function is
Form_Closing(ByVal eventSender As System.Object, ByVal eventArgs As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
in which the 'Cancel' Equivalent in the above VB function exists, but not the 'UnloadMode'. What i wanted to know is, how do i now find out if the Form s being closed by the user, or if it is coming from with in the application ?
Thanks in advance.
Form_QueryUnload( Cancel as Integer, UnloadMode as Integer)
which would be called when the form is being closed. The UnloadMode is used to find out if the Fomr is being closed by the user - in which case this event is to be cancelled - and if it is coming from within the application, then it would close the application.
In .NET, the equivalent Function is
Form_Closing(ByVal eventSender As System.Object, ByVal eventArgs As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
in which the 'Cancel' Equivalent in the above VB function exists, but not the 'UnloadMode'. What i wanted to know is, how do i now find out if the Form s being closed by the user, or if it is coming from with in the application ?
Thanks in advance.