WWW.NNC.IR
Basic Knowledge For Macro Customize Functions
210
Vision System FH/FZ5 Series
User’s Manual (Z340)
Variable Data Types
Before a variable can be used, the data area that will hold the data must be allocated. A data type defines the
size of the data area to be allocated and how the data is handled.
Data types and data ranges of variables that can be used in macro customize functions are described below.
Select the data type based on the use and objective of the variable.
Naming Rules for Variables
Rules exist for variable names. Decide variable names based on the rules below.
*1: "@" is a type identifier for reference variables, and cannot be used for variables that the user directly declares in the
program.
An identifier that identifies the type of data used as a variable is referred to as a "type identifier". Always add
a type identifier to the end of the variable name of each variable. For the type identifiers that can be used,
refer to "Variable Types and Type Identifiers".
Data type Description Data range
Number of bytes per data
item
Variable area
size
Integer Used for signed integer values.
-2147483648 to
2147483647
4 bytes
Variable length
Double
precision real
number
Used for double precision type
real numbers.
-1.0E30 to 1.0E30 8 bytes
Character
string
Used for character strings. Up to 255 characters Max. 256 bytes
Variable name
Start Middle End
Alphabet
('A' to 'Z', 'a' to 'z')
Alphabet, numbers, Symbols
('A' to 'Z', 'a' to 'z', '0' to '9', underline '_',
period '.'))
Type identifier
('&', '#', '$', '@')
(*1)
• A variable name that starts with a number cannot be used.
• A special mark cannot be used in a variable name.
• A variable name that is reserved cannot be used. However, a variable name that includes a reserved variable name
can be used.
Example: (Cannot be used) WAIT&
→ (Can be used) WAITTIME&
• Letters are not case sensitive.
Example: AA& and aa& are treated as the same variable.