Delete text DELETE
Removes Count characters from Position.
Text'AB--CD'
From3
Count2
Dest'ABCD'
| Tag | After two scans |
|---|---|
| CleanCode | 'ABCD' |
| DashCount | 2 |
| DashPos | 3 |
| RawCode | 'AB--CD' |
How it's used
Use DELETE to remove characters, such as dashes in a code.
Text'AB--CD'
From
Count
Dest'ABCD'
| Tag | Value |
|---|---|
| RawCode | 'AB--CD' |
| CleanCode | 'ABCD' |
2 characters from position 3 removed: ABCD.
Operands
| Operand | Data type | Read or write |
|---|---|---|
| Source | STRING or a number | Reads |
| Count | DINT or a number | Reads |
| Position | DINT or a number | Reads |
| Dest | STRING | Writes |
Common mistakes
- Using zero as the first characterPositions start at 1. Deleting a range does not change the source unless it is also the destination.