Include Files And System_Calls; Managing Large Programs; Include Files - AMX AXCESS CONTROL SYSTEM PROGRAM Instruction Manual

Programming language
Table of Contents

Advertisement

Include Files and System_Calls

Managing Large Programs

Include files and SYSTEM_CALLS are important in managing large programs, and in simplifying
basic programming. Include files allow you to break a large program into smaller, more
manageable files. SYSTEM_CALLS provide ready access to pre-canned programming solutions
and tools, without having to rewrite them.

Include files

Typically, your program will reside in a single file. Axcess program files are saved with a DOS
extension of .AXS. When you compile your program, Axcess compiles it in the computer's
memory, and when you save your program, Axcess saves it to disk.
In some cases, a program may be too large to fit into your computer's memory. In such a case, it is
possible to break the program up into multiple files. This is done by taking portions of your
program and putting them into one or more include files. An include file is a DOS file which is
included in the compiling process without having to reside in the computer's memory.
To include a file in a program, use the keyword INCLUDE, followed by the filename in single
quotes. For example:
DEFINE_PROGRAM
INCLUDE 'TEST.AXI'
When the compiler reaches the INCLUDE statement, it jumps into the specified file and continues
compiling. When it has reached the end of that file, it comes back to the line following the
INCLUDE statement and continues compiling, as shown in FIG. 26.
FIG. 26 Compilation flow using an Include file
The code compiled in the include file is compiled just as if it were in the main program where the
INCLUDE statement is located. The INCLUDE statement can appear anywhere in your program,
since it is actually a statement to the compiler, not the Axcess Control System. What you decide to
put into include files is up to you. Here are several suggestions for their use in large programs:
Axcess Programming Language
(* Program statements can go here *)
(* More program statements can go here *)
Include Files and System_Calls
95

Hide quick links:

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the AXCESS CONTROL SYSTEM PROGRAM and is the answer not in the manual?

This manual is also suitable for:

Axcess

Table of Contents