Attention
IronPLC can only run very simple programs. The steps described are accurate but many language features are not yet supported.
INSERT¶
Inserts a string into another string at a specified position.
IEC 61131-3 |
Section 2.5.1.5.7 |
Support |
Not yet supported |
Signatures¶
# |
Input (IN1) |
Input (IN2) |
Input (P) |
Return Type |
Support |
|---|---|---|---|---|---|
1 |
|
|
|
|
Not yet supported |
2 |
|
|
|
|
Not yet supported |
Description¶
INSERT(IN1, IN2, P) inserts IN2 into IN1 after position P.
Positions are 1-based. If P is 0, IN2 is inserted before the
first character.
Example¶
result := INSERT('Helo', 'l', 3); (* result = 'Hello' *)
result := INSERT('World', 'Hello ', 0); (* result = 'Hello World' *)