INSERT
(FUN)
FUNCTION INSERT : STRING(255)
Inserts a string into another string at a specific position
INSERT (STR1, STR2, POS)
means: Insert STR2
into STR1
after position POS
.
(* Example declaration *)
VarSTRING1 : STRING ;
(* Example in ST , result is 'SUXYSI' *)
VarSTRING1 := INSERT ('SUSI','XY',2);
- InOut:
Scope
Name
Type
Comment
Return
INSERT
STRING(255)
Resulting string
Input
STR1
STRING(255)
String into which
STR2
is insertedSTR2
STRING(255)
String to be inserted into
STR1
POS
INT
Insert position. IfPOS
is > 255 OR < 0, the result equalsSTR1
0
: Inserts before the first character1
: Inserts after the first character.