O'Reilly logo

C# Web Development with ASP.NET: Visual QuickStart Guide by Jose Mojica

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 11. Error Handling

It seems that every language has its own way of reporting error conditions. Take for example VBScript, which uses the error object (Err). To trap errors in VBScript, you use the On Error Resume Next function. Contrast that to the way that Windows, the operating system, reports error conditions. When you call one of the API functions, normally the function returns an error code as its output parameter. Depending on what function you call, the code may return 0 if the function was successful or a negative number if it was unsuccessful. However, other functions return 0 if the function was unsuccessful and a positive number if the function was successful. What Microsoft tried to do was unify the way that every language ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required