
22 CHARACTER STRING FUNCTIONS
22.6 Deleting Character String
823
22
22.6
Deleting Character String
DELETE(_E)
These functions delete an arbitrary range of a character string and output the result.
Setting data
■
Descriptions, types, and data types
Processing details
■
Operation processing
• These functions delete the data for the specified number of characters from an arbitrary position of a character string input
to (s) and output the remaining character strings from (d).
• The value input to (n1) specifies the number of characters to be deleted.
• The value input to (n2) specifies the number of the head character position of a character string to be deleted.
Ex.
When the value input to (n1) and (n2) is 5
• A value input to (s) is the STRING type data value and within the range from 0 to 255 byte(s).
• A value input to (n1) is the INT type data value and within the range from 0 to 255. (However, the value must be within the
number of characters of the character string to be input to (s).)
• A value input to (n2) is the INT type data value and within the range from 1 to 255. (However, the value must be within the
number of characters of the character string to be input to (s).)
Ladder diagram
Structured text
[Without EN/ENO]
[With EN/ENO]
[Without EN/ENO]
d:=DELETE(s,n1,n2);
[With EN/ENO]
d:=DELETE_E(EN,ENO,s,n1,n2);
Argument
Description
Type
Data type
EN
Execution condition (TRUE: Execution, FALSE: Stop)
Input variable
BOOL
s
Input
Input variable
STRING(255)
n1
Specification of number of characters to be deleted
Input variable
INT
n2
Specification of head character position of a character string to be
deleted
Input variable
INT
ENO
Output status (TRUE: Normal, FALSE: Abnormal)
Output variable
BOOL
d
Output
Output variable
STRING(255)
s
d
n1
n2
EN
ENO
d
s
n1
n2
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
3rd word
4th word
1st word
42H (B)
41H (A)
44H (D)
43H (C)
35H (5)
34H (4)
00H
High-order byte Low-order byte
High-order byte Low-order byte
"ABCDEF12345"
"ABCD45"
(s)
(d)
Head character
position of a
character string to
be deleted
n2
: 5th
character
Number of characters
to be deleted
n1
: 5
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: ......