Property:  Err.Number

object.Number [ = errnumber]

This property, which is the default property of the Err object, is used to retrieve or set the value that relates to a specific run-time error or SCODE. This value is automatically generated when an error occurs and is reset to zero (no error) after an On Error Resume Next statement or after using the Clear method.

Code:
On Error Resume Next
Err.Raise 10
Err.HelpFile = "userhelp.hlp"
Err.HelpContext = usercontextID
If Err.Number <> 0 Then
   MsgBox "Press F1 for help", , "Error: " & Err.Description, Err.Helpfile, _
                 Err.HelpContext
End If

Copyright 1999 by Infinite Software Solutions, Inc.
Trademark Information