473,396 Members | 1,764 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

difference between MyBase.Closing and MyBase.FormClosing

I read the Help and some of the many Google hits I got but can't find out
the difference between MyBase.Closing and MyBase.FormClosing
Can anyone tell me?


Thanks
Nov 6 '06 #1
4 7667
Academic wrote:
I read the Help and some of the many Google hits I got but can't find out
the difference between MyBase.Closing and MyBase.FormClosing
Can anyone tell me?
The Closing event is deprecated in .Net 2.0 and is provided for
backwards compatibility. You should use FormClosing from now on.
>From the docs:
"The Closing event is obsolete in the .NET Framework version 2.0; use
the FormClosing event instead."
Chris

Nov 6 '06 #2
I was wondering if anyone knows what is different
"Chris Dunaway" <du******@gmail.comwrote in message
news:11*********************@f16g2000cwb.googlegro ups.com...
Academic wrote:
>I read the Help and some of the many Google hits I got but can't find out
the difference between MyBase.Closing and MyBase.FormClosing
Can anyone tell me?

The Closing event is deprecated in .Net 2.0 and is provided for
backwards compatibility. You should use FormClosing from now on.
>>From the docs:

"The Closing event is obsolete in the .NET Framework version 2.0; use
the FormClosing event instead."
Chris

Nov 6 '06 #3
Academic,
In addition to the other comments.

FormClosing as an expanded EventArgs that include information about why the
form is closing.
http://msdn2.microsoft.com/en-us/lib...gs(VS.80).aspx

Where as Closing simply has a CancelEventArgs
http://msdn2.microsoft.com/en-us/lib...gs(VS.80).aspx

--
Hope this helps
Jay B. Harlow
..NET Application Architect, Enthusiast, & Evangelist
T.S. Bradley - http://www.tsbradley.net
" Academic" <ac************@a-znet.comwrote in message
news:e1****************@TK2MSFTNGP03.phx.gbl...
>I read the Help and some of the many Google hits I got but can't find out
the difference between MyBase.Closing and MyBase.FormClosing
Can anyone tell me?


Thanks
Nov 6 '06 #4
Thanks, I read the Help but didn't dig enough to find the CloseReason
Enumeration

Jay, I wish you'd look at my other post. I find that if I have a MDI form
open, and also a non-MDI non-MDI-Child Form open and close the app (by
clicking the X button) the non-MDI non-MDI-Child Form does not get a
FormClosing event.
Thanks again

PS By "non-MDI non-MDI-Child Form " I mean a regular run-of-the-mill form

"Jay B. Harlow" <Ja************@tsbradley.netwrote in message
news:7C**********************************@microsof t.com...
Academic,
In addition to the other comments.

FormClosing as an expanded EventArgs that include information about why
the form is closing.
http://msdn2.microsoft.com/en-us/lib...gs(VS.80).aspx

Where as Closing simply has a CancelEventArgs
http://msdn2.microsoft.com/en-us/lib...gs(VS.80).aspx

--
Hope this helps
Jay B. Harlow
.NET Application Architect, Enthusiast, & Evangelist
T.S. Bradley - http://www.tsbradley.net
" Academic" <ac************@a-znet.comwrote in message
news:e1****************@TK2MSFTNGP03.phx.gbl...
>>I read the Help and some of the many Google hits I got but can't find out
the difference between MyBase.Closing and MyBase.FormClosing
Can anyone tell me?


Thanks

Nov 7 '06 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Kathy D | last post by:
I have created an mdi parent form with four children. I want to disable closing the four children but allow closing the parent form. I created a FormClosing event on each form. That event tests...
1
by: e_man_online | last post by:
Hi, I have a VStudio 2003 project that had code like: Private Sub frmAnyForm_Closing(<parameters list...>) Handles MyBase.Closing and this project was converted to .NET 2.0 Everything...
2
by: polocar | last post by:
Hi, suppose that you have a C# form with two buttons, that are the classical "btnOk" and "btnCancel" (besides them, of course in the form there can be many other controls). When the user clicks...
9
by: cj | last post by:
In VB2003I have been using an exit menu item that issues me.close() then Private Sub Form1_Closing took care of closing everything down. I don't see a closing event for form1 in VB2005. What...
14
by: =?Utf-8?B?UHVjY2E=?= | last post by:
Hi, I'm using VS2005 and .net 2.0. I'm creating an application that has 3 forms. I want allow users to move forward and backward with the forms and retain the data users have entered. I thought...
3
by: sravan_reddy001 | last post by:
i want to prevent a form from closing.. to do this i want to handle the formClosing or FormClosed events. from here i want to prevent the form from closing. New instance of same form should...
19
by: zacks | last post by:
I have a .NET 2.0 MDI application where the child form has a Tab Control. Each of the Tab in the Tab Control has a Validating event to handle what it should do when the user changes tabs. But...
3
by: mtczx232 | last post by:
I have TabControls that Hold Forms on his TabPges (this make me easy to give ability to Designing each form in his IDE window). When form x is in middle of Edit Data Mode, I going to prevent:...
0
by: Academia | last post by:
I have a Mdi app. In FormClosing, e.CloseReason works OK in the Children. But in the Mdi form it always show UserClosing. Since the children close first I could set a global flag in them...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.