Sideway
output.to from Sideway
Draft for Information Only

Content

VBScript Properties of Err Object
 Description Property
  Syntax
  Argument
  Remark
  ReqVersion
  Applied to
 HelpContext Property
  Syntax
  Argument
  Remark
  ReqVersion
  Applied to
 HelpFile Property
  Syntax
  Argument
  Remark
  ReqVersion
  Applied to
 Number Property
  Syntax
  Argument
  Remark
  ReqVersion
  Applied to
 Source Property
  Syntax
  Argument
  Remark
  ReqVersion
  Applied to

VBScript Properties of Err Object

Some typical predefined Elements are.

  •  Object:
    •  Description Property
    •  Item Property
    •  Key Property
    •  CompareMode Property

Description Property

last updated 10 Dec 2017

is to set, if optional stringexpression is given, or to return the Description Property Value of Err Object.

Syntax

Err.Description [= stringexpression]

Argument

Err.DescriptionRequired Keywords. The keywords used to specify the Description Property of the Err Object.stringexpressionOptionial. But required for setting a string expression containing a description of the error.=Optionial. But required as assigning equal to operator for setting the value of Description to stringexpression.

Remark

  • The Description property consists of a short description of the error.
  • This property can be used to alert the user to an error that is not handled.
  • This property can be used to assign a short description of the error for generating a user-defined error.
  • If Description isn't filled in, and the value of Number corresponds to a VBScript run-time error, the descriptive string associated with the error is returned.

ReqVersion

1

Applied to

Err Object

HelpContext Property

last updated 10 Dec 2017

is to set, if optional contextID is given, or to return the context ID for a topic in a Help File of Err Object.

Syntax

Err.HelpContext [= contextID]

Argument

Err.HelpContextRequired Keywords. The keywords used to specify the HelpContext Property of the Err Object.contextIDOptionial. But required for setting a valid identifier for a Help topic within the Help file.=Optionial. But required as assigning equal to operator for setting the value of HelpContext to contextID.

Remark

  • If a Help file is specified in HelpFile, the HelpContext property is used to automatically display the Help topic identified.
  • If both HelpFile and HelpContext are empty, the value of the Number property is checked.
  • If it corresponds to a VBScript run-time error value, then the VBScript Help context ID for the error is used.
  • If the Number property doesn't correspond to a VBScript error, the contents screen for the VBScript Help file is displayed.

ReqVersion

2

Applied to

Err Object

HelpFile Property

last updated 10 Dec 2017

is to set, if optional contextID is given, or to return the fully qualified path to a Help File of Err Object.

Syntax

Err.HelpFile [= contextID]

Argument

Err.HelpFileRequired Keywords. The keywords used to specify the HelpFile Property of the Err Object.contextIDOptionial. But required for setting a fully qualified path to the Help file.=Optionial. But required as assigning equal to operator for setting the value of HelpFile to contextID.

Remark

  • If a Help file is specified in HelpFile, it is automatically called when the user clicks the Help button (or presses the F1 key) in the error message dialog box.
  • If the HelpContext property contains a valid context ID for the specified file, that topic is automatically displayed.
  • If no HelpFile is specified, the VBScript Help file is displayed.

ReqVersion

2

Applied to

Err Object

Number Property

last updated 10 Dec 2017

is to set, if optional errornumber is given, or to return numeric Number value of Err Object.

Syntax

Err.Number [= errornumber]

Argument

Err.NumberRequired Keywords. The keywords used to specify the Number Property of the Err Object.errornumberOptionial. But required for setting an integer representing a VBScript error number or an SCODE error value.=Optionial. But required as assigning equal to operator for setting the value of Number to errornumber.

Remark

  • Number is the Err object's default property.
  • When returning a user-defined error from an Automation object, set Err.Number by adding the pre-defined number as an error code to the constant vbObjectError.

ReqVersion

1

Applied to

Err Object

Source Property

last updated 10 Dec 2017

is to set, if optional stringexpression is given, or to return the Source Property of Err Object containing the object or application name that originally generated the error.

Syntax

Err.Source [= stringexpression]

Argument

Err.SourceRequired Keywords. The keywords used to specify the Source Property of the Err Object.stringexpressionOptionial. But required for setting a string expression representing the application that generated the error.=Optionial. But required as assigning equal to operator for setting the value of Source to stringexpression.

Remark

  • The Source property specifies a string expression that is usually the class name or programmatic ID of the object that caused the error. Use Source to provide your users with information when your code is unable to handle an error generated in an accessed object. For example, if you access Microsoft Excel and it generates a Division by zero error, Microsoft Excel sets Err.Number to its error code for that error and sets Source to Excel.Application. Note that if the error is generated in another object called by Microsoft Excel, Excel intercepts the error and sets Err.Number to its own code for Division by zero. However, it leaves the other Err object (including Source) as set by the object that generated the error.
  • Source always contains the name of the object that originally generated the error — your code can try to handle the error according to the error documentation of the object you accessed. If your error handler fails, you can use the Err object information to describe the error to your user, using Source and the other Err to inform the user which object originally caused the error, its description of the error, and so forth.
  • When generating an error from code, Source is your application's programmatic ID.

ReqVersion

1

Applied to

Err Object

©sideway

ID: 180500013 Last Updated: 5/13/2018 Revision: 0


Latest Updated LinksValid XHTML 1.0 Transitional Valid CSS!Nu Html Checker Firefox53 Chromena IExplorerna
IMAGE

Home 5

Business

Management

HBR 3

Information

Recreation

Hobbies 8

Culture

Chinese 1097

English 339

Reference 79

Computer

Hardware 249

Software

Application 213

Digitization 32

Latex 52

Manim 205

KB 1

Numeric 19

Programming

Web 289

Unicode 504

HTML 66

CSS 65

SVG 46

ASP.NET 270

OS 429

DeskTop 7

Python 72

Knowledge

Mathematics

Formulas 8

Algebra 84

Number Theory 206

Trigonometry 31

Geometry 34

Coordinate Geometry 2

Calculus 67

Complex Analysis 21

Engineering

Tables 8

Mechanical

Mechanics 1

Rigid Bodies

Statics 92

Dynamics 37

Fluid 5

Fluid Kinematics 5

Control

Process Control 1

Acoustics 19

FiniteElement 2

Natural Sciences

Matter 1

Electric 27

Biology 1

Geography 1


Copyright © 2000-2024 Sideway . All rights reserved Disclaimers last modified on 06 September 2019