Edit

Share via


TextConst.IndexOfAny(Text [, Integer]) Method

Version: Available or changed with runtime version 15.1.

Reports the one-based index of the first occurrence of the specified string in this instance. The search starts at a specified character position.

Syntax

Index :=   TextConst.IndexOfAny(Values: Text [, StartIndex: Integer])

Parameters

TextConst
 Type: TextConst
An instance of the TextConst data type.

Values
 Type: Text
The collection of characters to seek.

[Optional] StartIndex
 Type: Integer
The one-based search starting position.

Return Value

Index
 Type: Integer
The one-based index of the first occurrence of the specified string in this instance. If the index returned is 0, the value is not present in the string.

See Also

TextConst data type
Getting started with AL
Developing extensions