FirstClassトップページ


 ヘルプの目次
このヘルプについて このヘルプについて
 
エンドユーザ向けヘルプ エンドユーザ向けヘルプ
Client Help クライアントヘルプ
Web Help Webアクセスヘルプ
ScreenReader Help スクリーンリーダ
Form フォーム
Synchronization 同期
Definitions 用語
container コンテナ
 
管理者向けヘルプ 管理者向けヘルプ
Administration サーバの管理
Internet Services インターネットサービス
Customization Tools カスタマイズツール(英語)
Administering OTSW OTSWの管理
OTSW Custodian OTSW Custodian
Using FirstClass ED FirstClass ED(英語)
 
バナー:
 
 Error
 
Purpose
Controls error handling. You can use this command to prevent runtime errors from stopping the program.
Syntax
On Error Goto Label
On Error Resume
On Error Resume Next
On Error Goto 0
This command is used with the following commands:


Goto Label
Processing jumps to the line that starts with the label if a critical error occurs.
The label can be either a line number (consisting of the numbers 0-9) or an alphanumeric string (as long as it does not start with a number). The label must be the first nonblank characters on the line followed by a colon (:).
Resume
The application will try to re-execute the line that caused the error until it executes successfully.
Be careful about using this command, because the application could loop on this line indefinitely.
Resume Next
Processing resumes with the line after the line that caused the error, including critical errors.
Any lines that cause errors are skipped, and processing doesn't stop for critical errors.
Goto 0
Turns off error handling from this point on.

Example
Sub Main()
        Dim i As Integer
        On Error Goto ErrHandler
        i=1/0           'division by zero error
                Print "Error handling has resumed execution here"
Exit Sub

 

Copyright(C) 2002-2011 FC Management Co. All Rights Reserved