Cross-block comments (#COMMENT BEGIN/END)
Syntax: | |
#COMMENT BEGIN | Start of comment block |
: | Disabled area. All lines are ignored by the |
: | NC kernel without evaluation. |
#COMMENT END | End of comment block |
Both commands must be programmed in a separate NC line, i.e. further NC commands in the same block are not permissible. An exception is a line-by-line comment that must be bracketed "(" and ")".
Comment blocks can be defined inside or outside an NC program. However, they are restricted to the current file since calls from and returns from global subroutines included in the comments are not evaluated.
Application-specific nesting of comments can be enabled.
Programing Example
Cross-block comments
: | |
#COMMENT BEGIN | Start of comment block 1 |
... | |
#COMMENT BEGIN | Start of comment block 2 |
... | |
#COMMENT END | End of comment block 2 |
... | |
#COMMENT END | End of comment block 1 |
: | |
Nesting disabled: | |
: | |
#COMMENT BEGIN | Start of comment block 1 |
... | |
#COMMENT BEGIN | Start of comment block 2 |
... | |
#COMMENT END | End of comment block 1 and 2 |
: |
In the following cases, the NC kernel generates error messages:
- "End of File" is read in within a comment block.
- #COMMENT END is read in without a previously programmed #COMMENT BEGIN.
- After commend commands, further NC commands are programmed in the same block.