473,810 Members | 2,948 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Newby: Unexpected Error Handling in C# Web Applications

Hi:

I'm a VB.NET web programmer who is writing my first C# web application!

I'm having a problem trapping and logging unexpected errors. In my VB.NET
applications I have a routine called by global.asax that will trap the error
and write it to a text file. I've tried to convert that code and I'm totally
confused!

(This is not about try/catch)

I've searched MSDN and Google and there are very complicated examples
however I need something simple to start with. I need to know the error and
the various fields on the screen so I can debug in the event of an
unexpected crash.

If anyone knows of a SIMPLE example then I would appreciate hearing about
it.

Thanks very much!

Fred
Nov 17 '05 #1
3 1753
If you have the code in VB.NET and you want it converted to C#, I'll be glad
to do it for you if you post it. You can trap the exception doing exactly
what you mention, but I don't know about getting all of the fields on the
page, out of the box I'm not sure there's a way to do that b/c those fields
may have nothing to do with the error and not even in the scope of it.

--
W.G. Ryan, MVP

www.tibasolutions.com | www.devbuzz.com | www.knowdotnet.com
"Fred Nelson" <fr**@smartybir d.com> wrote in message
news:OL******** ******@TK2MSFTN GP15.phx.gbl...
Hi:

I'm a VB.NET web programmer who is writing my first C# web application!

I'm having a problem trapping and logging unexpected errors. In my VB.NET
applications I have a routine called by global.asax that will trap the
error
and write it to a text file. I've tried to convert that code and I'm
totally
confused!

(This is not about try/catch)

I've searched MSDN and Google and there are very complicated examples
however I need something simple to start with. I need to know the error
and
the various fields on the screen so I can debug in the event of an
unexpected crash.

If anyone knows of a SIMPLE example then I would appreciate hearing about
it.

Thanks very much!

Fred

Nov 17 '05 #2
If it's under 100 lines, use the Demo Edition of our Instant C# VB.NET to C#
converter - ASP.NET Converter tab (www.instantcsharp.com). If it's longer
than that contact us directly.

David Anton
www.tangiblesoftwaresolutions.com
Home of the Instant C# VB.NET to C# converter
and the Instant VB C# to VB.NET converter

"Fred Nelson" wrote:
Hi:

I'm a VB.NET web programmer who is writing my first C# web application!

I'm having a problem trapping and logging unexpected errors. In my VB.NET
applications I have a routine called by global.asax that will trap the error
and write it to a text file. I've tried to convert that code and I'm totally
confused!

(This is not about try/catch)

I've searched MSDN and Google and there are very complicated examples
however I need something simple to start with. I need to know the error and
the various fields on the screen so I can debug in the event of an
unexpected crash.

If anyone knows of a SIMPLE example then I would appreciate hearing about
it.

Thanks very much!

Fred

Nov 17 '05 #3
David:

Thank you VERY much - your conversion program is FANTASTIC!

Fred
"David Anton" <Da********@dis cussions.micros oft.com> wrote in message
news:69******** *************** ***********@mic rosoft.com...
If it's under 100 lines, use the Demo Edition of our Instant C# VB.NET to C# converter - ASP.NET Converter tab (www.instantcsharp.com). If it's longer
than that contact us directly.

David Anton
www.tangiblesoftwaresolutions.com
Home of the Instant C# VB.NET to C# converter
and the Instant VB C# to VB.NET converter

"Fred Nelson" wrote:
Hi:

I'm a VB.NET web programmer who is writing my first C# web application!

I'm having a problem trapping and logging unexpected errors. In my VB.NET applications I have a routine called by global.asax that will trap the error and write it to a text file. I've tried to convert that code and I'm totally confused!

(This is not about try/catch)

I've searched MSDN and Google and there are very complicated examples
however I need something simple to start with. I need to know the error and the various fields on the screen so I can debug in the event of an
unexpected crash.

If anyone knows of a SIMPLE example then I would appreciate hearing about it.

Thanks very much!

Fred

Nov 17 '05 #4

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

Similar topics

2
4349
by: Anil K. Gupta | last post by:
Hello, I am developing an application similar to MSN Messenger using C#.Net. I am using the Frameworks' System.Net.Sockets class for creating sockets and then communicating.Everything seems to work fine when there is internet connection, but once the application is started and then if there is a breakdown in the network then the application is getting terminated unexpectedly. I tried to handle the exceptions but nothing is working. The...
17
1663
by: Fred Nelson | last post by:
Hi: I'm trying to implement an overall error handler in my VB.NET windows application. I need to place an "On Error Goto" in "Sub Main". I have tried to create a Sub Main and have had no luck - all the examples I've read don't explain this to me either.
5
4523
by: r.nikhilk | last post by:
Hi, Currently, we are porting C++ applications from 32 bit to 64 bit on AIX platform. (The current version of AIX is 5.3 and xlC verison is 8.0). We are able to compile the applications by including the -q64 option in xlC compiler. And we are able to link all these libraries to one of the main applications and generate an executable. SKLoader. But, when we try to run this main executable, we are getting the following errors:
2
1522
by: jbolty | last post by:
There have been a few threads talking about using the tilde ~, to reference the webroot path. My problem though is handling an unexpected tilde in a url. this url: http://localhost/mysite/~Default.aspx returns this error:
4
1974
by: John Wright | last post by:
I need some good ideas or references for robust error handling in VB.NET. I am using try catch but find myself using the generic exception handler. I would like to get more precise error handling so I can take appropriate action and display user friendly error messages back to the client. The problem I am getting is determining which error types can be thrown for each function/sub and handling them. Is there a way to determine all the...
1
8852
by: Mrozik | last post by:
Hi! I have a problem - after deploying application in client environment, on some client machines occured error. Environment: App server: ASP.NET WebService/Win 2003/ secured SSL (.NET 2.0) Client app: SmartClient - WinForms (.NET 2.0) I trust all server cetrificates - at the start of client application I call:
5
1834
by: alexrixhardson | last post by:
Hi guys, I am a newby in the C/C++ world, and I am beginning to work on a rather simple TCP/IP proxy application which must be able to handle large volume of data as quickly as possible. Since this application has to process and distribute plain text around the network, I am wondering if there are any peformance differences between C++ std::string and C char in run time?
2
1971
by: Axel Gallus | last post by:
I am desperately looking for some resources dealing with error handling in c++. Don't get me wrong.... I have very detailed knowledge of exceptions, assertions and invariants, but what is missing it the following: 1.) When developing a commercial application, how does the usage of exceptions and assertions as well as
2
3636
by: atishrg | last post by:
Hello All Need your help.. I created addin for outlook 2007 in vs2005(vb.net)... It is working fine now I Migrated that to vs2008 and created setup for that in vs2008...
0
9603
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10643
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10378
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
10121
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
6881
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5550
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5690
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4333
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
3015
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.