
828
22 CHARACTER STRING FUNCTIONS
22.8 Searching Character String
22.8
Searching Character String
FIND(_E)
These functions search for a character string and output the result.
Setting data
■
Descriptions, types, and data types
Processing details
■
Operation processing
• These functions search for a character string input to (s2) from the start of the character string input to (s1) and output the
result from (d).
• This function outputs the head character position of the searched character string detected first as the search result.
• If a character string specified by (s2) cannot be searched from the one specified by (s1), these functions output "0".
• A value input to (s1) and (s2) is the STRING type data value and within the range from 0 to 255 byte(s).
Ladder diagram
Structured text
[Without EN/ENO]
[With EN/ENO]
[Without EN/ENO]
d:=FIND(s1,s2);
[With EN/ENO]
d:=FIND_E(EN,ENO,s1,s2);
Argument
Description
Type
Data type
EN
Execution condition (TRUE: Execution, FALSE: Stop)
Input variable
BOOL
s1, s2
Input
Input variable
STRING(255)
ENO
Output status (TRUE: Normal, FALSE: Abnormal)
Output variable
BOOL
d
Output
Output variable
INT
s1
d
s2
EN
ENO
d
s1
s2
"ABCD1234567"
32H (2)
31H (1)
34H (4)
33H (3)
00H
High-order byte Low-order byte
"1234"
2nd word
3rd word
1st word
42H (B)
41H (A)
44H (D)
43H (C)
32H (2)
31H (1)
34H (4)
33H (3)
36H (6)
35H (5)
00H
37H (7)
High-order byte Low-order byte
2nd word
3rd word
4th word
5th word
6th word
1st word
Value to be input to IN2
Value to be input to IN1
Output value
INT
5
Search of
character string
Summary of Contents for MELSEC iQ-F FX5 series
Page 1: ...MELSEC iQ F FX5 Series Programming Manual Instructions Standard Functions Function Blocks ...
Page 2: ......
Page 21: ...19 PART 1 PART 1 OVERVIEW Part 1 consists of the following chapter 1 OVERVIEW ...
Page 98: ...96 4 STANDARD FUNCTIONS FUNCTION BLOCKS 4 2 Standard Function Blocks MEMO ...
Page 840: ...838 23 TIME DATA FUNCTIONS 23 4 Division MEMO ...
Page 887: ......