EasyManuals Logo

Mitsubishi MELSEC iQ-F FX5 series User Manual

Mitsubishi MELSEC iQ-F FX5 series
888 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #817 background imageLoading...
Page #817 background image
22 CHARACTER STRING FUNCTIONS
22.2 Extracting Character String Data from the Left/Right
815
22
22.2 Extracting Character String Data from the Left/
Right
LEFT(_E), RIGHT(_E)
• LEFT(_E): These functions output specified number of characters from the left of input character string data.
• RIGHT(_E): These functions output specified number of characters from the right of input character string data.
Setting data
â– Descriptions, types, and data types
Processing details
â– Operation processing
•LEFT(_E)
Ex.
When the value input to (n) is 7
Ladder diagram Structured text
[Without EN/ENO] [With EN/ENO] [Without EN/ENO]
d:=LEFT(s,n);
d:=RIGHT(s,n);
[With EN/ENO]
d:=LEFT_E(EN,ENO,s,n);
d:=RIGHT_E(EN,ENO,s,n);
Argument Description Type Data type
EN Execution condition (TRUE: Execution, FALSE: Stop) Input variable BOOL
s Input Input variable STRING(255)
n Specification of number of characters to be extracted Input variable INT
ENO Output status (TRUE: Normal, FALSE: Abnormal) Output variable BOOL
d Output Output variable STRING(255)
These functions output the data for the specified number of characters from the left of a character string input to (s) from (d).
The value input to (n) specifies the number of characters to be extracted.
s d
n
EN ENO
sd
n
42H (B) 41H (A)
44H (D) 43H (C)
46H (F) 45H (E)
32H (2) 31H (1)
34H (4) 33H (3)
00H 35H (5)
2nd word
3rd word
4th word
5th word
6th word
1st word
2nd word
4th word
3rd word
1st word
42H (B) 41H (A)
44H (D) 43H (C)
00H
46H (F)
31H (1)
45H (E)
High-order byte Low-order byte High-order byte Low-order byte
"ABCDEF12345" "ABCDEF1"
Number of
characters to be
extracted (L): 7

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Mitsubishi MELSEC iQ-F FX5 series and is the answer not in the manual?

Mitsubishi MELSEC iQ-F FX5 series Specifications

General IconGeneral
BrandMitsubishi
ModelMELSEC iQ-F FX5 series
CategoryController
LanguageEnglish

Related product manuals