TACL Reference Manual
Built-In Functions and Variables
HP NonStop TACL Reference Manual—429513-018
9-51
#CHARDEL Built-In Function
#CHARDEL Built-In Function
Use #CHARDEL to delete characters from a variable level, starting at a character
address.
variable-level
is an existing variable level from which the characters are to be deleted. It must not
be in a shared segment and must not be a DIRECTORY, a STRUCT, or a
STRUCT item.
char-addr-1
is an integer greater than zero or a variable level that contains an integer greater
than zero. char-addr-1 specifies the character position at which character
deletion is to begin. The character position must be in the range from 0 to max-
int, inclusive.
char-count
is an integer or a variable level that contains an integer. char-count specifies the
number of lines to be deleted. The line count must be in the range from 0 to max-
int, inclusive.
char-addr-2
is an integer or a variable level that contains an integer. char-addr-2 specifies
the line number at which line deletion is to end. The line address must be in the
range from 0 to max-int, inclusive.
Result
#CHARDEL returns nothing.
Considerations
•
If you use TO, the character specified by char-addr-2 is included in the deletion.
That is, “x TO y” is equivalent to “x FOR (y-x+1).”
•
If you use TO and char-addr-1 is greater than char-addr-2, or if you use FOR
and char-count is zero, no deletion occurs.
•
If you omit both FOR and TO, TACL deletes the character specified by char-
addr-1.
•
Any part of the specified deletion that lies beyond the end of the variable level is
ignored.
#CHARDEL variable-level char-addr-1
[ [ FOR char-count ] | [ TO char-addr-2 ] ]