-

FIND_WSTRING

Type Function
Description Detects the position of a substring connected to IN2 within a given string connected to IN1. The character position of the first occurrence of the input string IN2 in IN1 is stored to OUT.

If no occurrence of the substring connected to IN2 is found or no substring (empty string '') is applied to IN2, then OUT := 0.
Notes
  • The first position in a string is 1.
  • Problem for calculation of position and length: Characters in WSTRING can have a size of 2 bytes or 4 bytes. Due to this, there may be calculation problems on 4-byte containing character STRINGs with 2-byte oriented position and length.
Parameters Inputs

IN1

IN2

Output

OUT
Error behavior Error behavior
Additional information EN/ENO behavior