DELETE

Deletes a part of a message string.
lrsf_de1
Arguments
IN
IN
MESSAGE
Any non-empty string
NbC
NbC
DINT
Number of characters to be deleted
Pos
Pos
DINT
Position of the first deleted character (first character of the string has position 1)
DELETE
Q
MESSAGE
modified string
empty string if Pos < 1
initial string if Pos > IN string length
initial string if NbC <= 0
Example
(* FBD Program using "DELETE" Function *)
lrsf_de2
(* ST Equivalence: *)
complete_string := 'ABCD' + 'EFGH'; (* complete_string is 'ABCDEFGH' *) sub_string := DELETE (complete_string, 4, 3); (* sub_string is 'ABGH'*)
Provide Feedback
Have questions or feedback about this documentation? Please submit your feedback here.
Normal