|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Get inside! Sample the range of functionality easily built with JMSL Library for Time Series Data Analysis, Heat Maps, Portfolio Optimization, Monte Carlo Simulation, Stock Price Charting and more. Download Now! |
|
#1
|
|||
|
|||
|
Error Handeling
I want To handel the error messages by myself in one part in my script.
I know that in VB I can Use the statment - On error resume next And I also know that I can retrive the Error Number In VB with Err.Number. How can I handel the errors by myself in ASP? I heard about the ASPErr Object, Is it the same thing like the err object in VB? thanks, ben. |
|
#2
|
|||
|
|||
|
Well you can do the exact same thing in ASP here is an example:
<%@ Language=VBScript %> <%Option Explicit%> <% 'NOTICE the Option Explicit at the beginning On error resume next Dim z z = 2 y = 3 'NOTICE I HAVEN'T DECLARE THE VARIABLE y If Err.number <> 0 Then Response.Write "Number : " & Err.number & "<br>" Response.Write "Description : " & Err.Description & "<br>" Response.Write "Source : " & Err.Source & "<br>" Response.End End If %> Hope this helps! Sincerely Vlince |
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > ASP Programming > Error Handeling |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|