Err.Clear
On Error Resume Next ' resume if an error occurs
'Do somethign that might cause an error
If Err.number <> 0 Then ' check if any errors were raised and handle them
'Handle the Error
response.write(Err.Description)
End If
On Error GoTo 0 ' turn off resume next