471,071 Members | 1,427 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

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

Determining Cause of Errors in VB.NET WEB Application

I'm devloping a Web Application in VB.NET. In my web.config file I have
specified that untrapped errors are to be sent to the page "errorpage.aspx".
This is working fine - if an untrapped error occurs the application is
indeed routed to this page.

On this page I would like to determine the cause of the error and either log
it in a file or send it to me via e-mail.

I am able to determine the page that sent me there from the URL parameter
"aspxerrorpath" - I would also like to be able to determine what went
wrong - or at least a line number where the failure occured.

I have the following code that I have seen in a vb.net web programming book:

dim appException as system.exception = server.getlasterror

This always returns a NULL value - no help at all!

Does anyone know how to determine the cause of an error when you have been
routed to the error page specified in the web.config file? I hope that its
possible to determine more than just the page that caused the error.

Your help would be greatly appreciated!

Nov 19 '05 #1
1 1103
Are you also known as "Fred" ?

See
http://www.error-bank.com/microsoft....bl_Thread.aspx

Your message is eerily similar to Fred's message,
even down to the misspelling of "devloping".

*That "Fred" said that
"I did get a response that may solve my issue from that group!"

Please don't pull our chains, OK ?

Either you're "daniel" or you're "Fred".
Don't waste our time here.

Thank you for your cooperation.

If you have any legitimate questions,
don't hesitate to ask them here.

Juan T. Llibre
ASP.NET MVP
===========
"daniel" <a9******@anet.net.tw> wrote in message
news:%2****************@TK2MSFTNGP12.phx.gbl...
I'm devloping a Web Application in VB.NET. In my web.config file I have
specified that untrapped errors are to be sent to the page
"errorpage.aspx".
This is working fine - if an untrapped error occurs the application is
indeed routed to this page.

On this page I would like to determine the cause of the error and either
log
it in a file or send it to me via e-mail.

I am able to determine the page that sent me there from the URL parameter
"aspxerrorpath" - I would also like to be able to determine what went
wrong - or at least a line number where the failure occured.

I have the following code that I have seen in a vb.net web programming
book:

dim appException as system.exception = server.getlasterror

This always returns a NULL value - no help at all!

Does anyone know how to determine the cause of an error when you have been
routed to the error page specified in the web.config file? I hope that
its
possible to determine more than just the page that caused the error.

Your help would be greatly appreciated!

Nov 19 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.

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.