Global Header File
Customizing SQABasic Scripts
To edit an existing project-wide header file:
1. Click File
2. In Files of type, select Header Files (*.sbh).
3. Click the file to edit, and then click Open.
Adding Declarations to the Global Header File
For your convenience, Robot provides a blank header file called Global.sbh.
Global.sbh is a project-wide header file stored in SQABas32 in the project. You can
add declarations to this global header file and/or create your own.
To open Global.sbh:
1. Click File > Open > SQABasic File.
2. Set the file type to Header Files (*.sbh).
3. Select global.sbh, and then click Open.
Using SQABasic Header Files
After you finish adding global declarations to an SQABasic header file, save the file
before you compile a script or library file that references the header file. Save the
header file by clicking the Save toolbar button.
You do not compile SQABasic header files.
Header and Library Source File Examples
The following examples show how a script can reference:
Variables and constants declared in a header file.
Procedures declared in the header file and defined in a library source file.
To run the example, type the contents of each example file into an empty .rec script
file, .sbh header file, and .sbl library source file. Before attempting to run the script,
save the .sbh file and compile the .sbl file.
NOTE: These examples are also provided in the Robot Help. (See header files in
the Help Index.) You can copy the examples from the Help into your own files.