Click here to Skip to main content
16,014,940 members
Home / Discussions / Visual Basic
   

Visual Basic

 
AnswerRe: promblem Pin
Christian Graus17-Jan-07 0:22
protectorChristian Graus17-Jan-07 0:22 
AnswerRe: promblem Pin
Jason McBurney17-Jan-07 6:52
Jason McBurney17-Jan-07 6:52 
Questionquery in vb.net [modified] Pin
amaneet16-Jan-07 21:24
amaneet16-Jan-07 21:24 
AnswerRe: query in vb.net Pin
Guffa16-Jan-07 22:01
Guffa16-Jan-07 22:01 
GeneralRe: query in vb.net [modified] Pin
amaneet16-Jan-07 22:25
amaneet16-Jan-07 22:25 
GeneralRe: query in vb.net Pin
nlarson1117-Jan-07 4:20
nlarson1117-Jan-07 4:20 
QuestionGlobal Error Handling Pin
MatthysDT16-Jan-07 20:58
MatthysDT16-Jan-07 20:58 
AnswerRe: Global Error Handling Pin
Dave Sexton17-Jan-07 0:25
Dave Sexton17-Jan-07 0:25 
Sure there is but it may not always prove to be user friendly.

For WinForms...
One of the new features of VB.NET 2005 is the ability to specify code to run when your app encounters an unhandled exception. You can set this up by going into the code editor of the Application.Designer.vb file & writing or referencing code for the MyApplication_UnhandledException event. By default the Application.Designer.vb file is hidden & it is not recommended to modify it directly but this is the only way I know to set this up.

You can also get all information regarding the exception (including stack trace, etc.) from the EventArgs passed to the handler.

I wouldn't recommend this to be the only way you handle errors in your code tho. It's a nice feature but not a replacement for good coding & planning.

For WebApps...
What I usually do is set it up using a Global.asax file. The Global.asax file has an Application_Error event handler that handles any errors that occur in your web app. You can log these errors using the Server.GetLastError() method & then redirect the user to a custom error page or whatever.

Hope that helps.
AnswerRe: Global Error Handling Pin
Christian Graus17-Jan-07 0:35
protectorChristian Graus17-Jan-07 0:35 
QuestionVertical Label Pin
Laji5916-Jan-07 20:36
Laji5916-Jan-07 20:36 
AnswerRe: Vertical Label Pin
MatthysDT17-Jan-07 0:50
MatthysDT17-Jan-07 0:50 
QuestionCan I make a Crystal Report using dataview Pin
hisuman10016-Jan-07 20:08
hisuman10016-Jan-07 20:08 
QuestionGet Words from .doc, .rtf, .htm [modified] Pin
Kumaran21cen16-Jan-07 19:54
Kumaran21cen16-Jan-07 19:54 
AnswerRe: Get Words from .doc, .rtf, .htm Pin
Christian Graus16-Jan-07 20:50
protectorChristian Graus16-Jan-07 20:50 
GeneralRe: Get Words from .doc, .rtf, .htm Pin
Jason McBurney17-Jan-07 6:55
Jason McBurney17-Jan-07 6:55 
Questioninheritance problem? Pin
moize1216-Jan-07 14:28
moize1216-Jan-07 14:28 
AnswerRe: inheritance problem? Pin
Christian Graus16-Jan-07 15:02
protectorChristian Graus16-Jan-07 15:02 
AnswerRe: inheritance problem? Pin
Guffa16-Jan-07 22:19
Guffa16-Jan-07 22:19 
AnswerRe: inheritance problem? Pin
Dave Sexton17-Jan-07 0:40
Dave Sexton17-Jan-07 0:40 
Questionmaxlength of textbox Pin
ctlqt1216-Jan-07 13:28
ctlqt1216-Jan-07 13:28 
AnswerRe: maxlength of textbox Pin
Christian Graus16-Jan-07 15:06
protectorChristian Graus16-Jan-07 15:06 
QuestionUpdating/Patching Pin
spelltwister16-Jan-07 13:27
spelltwister16-Jan-07 13:27 
QuestionWord.doc Pin
Anybloodyid16-Jan-07 11:39
Anybloodyid16-Jan-07 11:39 
AnswerRe: Word.doc Pin
shreekar16-Jan-07 17:49
shreekar16-Jan-07 17:49 
GeneralRe: Word.doc Pin
Anybloodyid16-Jan-07 23:10
Anybloodyid16-Jan-07 23:10 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.