7-234
RIGHT(P),LEFT(P)
Program Example
(1) The following program stores 4 characters of data from the rightmost of the character string
stored in the area starting from R0, and stores it into the area starting from D0 when X0 is
turned ON.
[Ladder Mode] [List Mode]
[Operation]
(2) The following program stores the number of characters corresponding to the value being
stored in D0 from the left of the character string data being stored at D100 to the area
starting from R10 when X1C is turned ON.
[Ladder Mode] [List Mode]
[Operation]
Instruction Device
Step
R1
42H (B)41H (A)
32H (2)31H (1) D1
30H (0)45H (E)
46H (F)41H (A)
30H (0)45H
(E)
46H (F)41H (A)
00H
R2
R3
R4
D2 00H
ASCII code for the 4th character
"BA210EFA"
"0EFA"
R0 D0
b15 b8b7 b0 b15 b8b7 b0
Instruction Device
Step
D101
53H (S)51H (Q)
4FH (O)4EH (N)R11
53H (S)51H (Q)
4FH (O)4EH (N)
48H (H)44H (D)
41H (A)42H (B)
00H
D102
D103
D104
R12
ASCII code for the 6th character
"SQONHDAB""SQONHD"
D100 R10
00H
48H (H)44H (D)
R13
6D0
b15 b8b7 b0 b15 b8b7 b0