Login
Register
Tutorials
Forum
Career Development
Resources
Reviews
Jobs
Interview
Communities
Projects
Training
Silverlight Games
|
Bookmarks
|
New Members FAQ
|
Mentor
|
Code Converter
|
IT Companies
|
Peer Appraisal
|
Members
|
Revenue Sharing
|
Computer Jokes
|
New Posts
|
Social
|
Talk to Webmaster Tony John
Online Members
Padma
naveensanagasetti
Ultimaterengan
Amruta
More...
Resources
»
.NET programming
»
.NET Framework
Windows Exception in Dot Net
Posted Date:
25-Dec-2008
Category:
.NET Framework
Author:
Vijayaragavan.R
Member Level:
Bronze
Points
: 2
As we have declared as Int16 in the program the input must be entered as a number in the Input Textbox. But instead if we enter a Decimal Number. Actually this is a format exception Error. But instead of giving separate exception for format and Overflow errors. We can give system Exception as a common error. This windows exception handles all the Known and Unknown Errors that is specified.
CODING:
Private Sub CoversionButton_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CoversionButton.Click
Try
Decimal1 = System.Double.Parse(InputTextBox.Text)
Decimal2 = 10.11 Decimal2 += 10.645 ResultListBox.Items.Add(Decimal2.ToString("0.00"))
Dim Stri = Decimal2.ToString("0.00")
ResultListBox.Items.Add("ToString():" & Stri)
Decimal1 = System.Convert.ToSingle("decimal2")
Catch ex As SystemException MessageBox.Show(ex.ToString, "Unknown Error ", MessageBoxButtons.OK, MessageBoxIcon.Error)
End Try
End Sub
Did you like this resource? Share it with your friends and show your love!
Tweet
Responses to "Windows Exception in Dot Net"
No responses found. Be the first to respond...
Feedbacks
Post Comment:
Notify me by email when others post comments to this article.
Do not include your name, "with regards" etc in the comment. Write detailed comment, relevant to the topic.
No HTML formatting and links to other web sites are allowed.
This is a strictly moderated site. Absolutely no spam allowed.
Name:
Sign In
to fill automatically.
Email:
(Will not be published, but
required
to validate comment)
Type the numbers and letters shown on the left.
Next Resource:
OverFlow Exception in Dot Net
Previous Resource:
Debug Logical Errors in Dot Net
Return to Resources
Post New Resource
Category:
.NET Framework
Post resources and
earn money
!
More Resources
Error Handling in Dot Net
Data Type in .Net
About Reflection
Top 10 Reasons for Using .Net Framework
FindLocation in Map
Mappoint
Popular Tags
Tag posting guidelines
Search Tags
Windows Exception in Dot Net
.
Active Members
Today
Ultimaterengan
(45)
Padma
(10)
Amruta
(6)
Last 7 Days
baskar
(312)
naveensanagase...
(183)
Ultimaterengan
(180)
more...
Awards & Gifts
Email subscription
.NET Jobs
.NET Articles
.NET Forums
Articles Rss Feeds
Forum Rss Feeds