Programming
2.7 Functions
Expanding the user interface
2-74
Commissioning Manual, 11/2006, 6FC5397-0DP10-0BA0
2.7.4
Check Variable (CVAR)
Description
You can use the CVAR (CheckVariable) function to run a scan to ascertain whether all or
only certain variables or Help variables in a screen form are error-free.
It may be useful to check if variables contain a valid value before an NC code with the GC
function. A variable is error-free if the state of the variable Identifier.vld = 1.
Programming
Syntax:
CVAR(
VarN)
Description:
Checks variables for valid content
Parameters:
VarN
List of variables to be checked.
Up to 29 variables, each separated by a comma, can
be checked. A character length of 500 must not be
exceeded.
The result of the scan can be:
1 = TRUE (all variables have valid content)
0 = FALSE (at least one variable has invalid content)
Example
IF CVAR == TRUE
; Check all variables
VS8.SE = 1
; If all variables are error-free, softkey VS8 is
visible
ELSE
VS8.SE = 2
; If a variable has an invalid value, softkey VS8 is
disabled
ENDIF
IF CVAR(”VAR1”, ”VAR2”) ==
TRUE
; Check variables VAR1 and VAR2
DLGL ("VAR1 and VAR2 are
OK")
; If the values of VAR1 and VAR2 are error-free,
"VAR1 and VAR2 are OK" appears in the dialog line
ELSE
DLGL ("VAR1 and VAR2 are not OK")
; If the values of VAR1 and VAR2 are invalid, "VAR1
and VAR2 are not OK" appears in the dialog line
ENDIF
Summary of Contents for SINUMERIK
Page 6: ...Preface Base software and HMI Advanced 6 Commissioning Manual 03 2009 6FC5397 0DP10 3BA0 ...
Page 96: ......
Page 562: ...Index Expanding the user interface Index 4 Commissioning Manual 11 2006 6FC5397 0DP10 0BA0 ...
Page 566: ...Table of contents Online Help HE1 4 Commissioning Manual 11 2006 6FC5397 0DP10 0BA0 ...
Page 598: ...Online Help HE1 Commissioning Manual 11 2006 6FC5397 0DP10 0BA0 36 ...