Skip to main content

7.9.9 FIND

Function

FIND is called a string search function. It searches for the position of string IN2 in the current string IN1, and OUT outputs the position of the first string searched

LD graphics

Alt text

Parameter description

Interface variableDeclarationData typeDescription
IN1InputSTRINGString
IN2InputSTRINGString
Function nameReturn valueINTString position

Corresponding syntax

  • IN1: current string
  • IN2: Search string
  • OUT: the first position of the character

Example

  • LD sample animation is as follows:

alt text

  • ST example is shown in the following code:
OUT:=FIND(IN1:=IN1,IN2:=IN2);