Previous Topic Next topic Print topic


&INDEX

Search a string, from left to right, for the first occurrence of a character-string. Then, return a number identifying the character position.
Restriction: This topic applies only when the AppMaster Builder AddPack has been installed, and applies only to Windows platforms.

Syntax:

&INDEX( `wholestring', `characterstring')

Aliases:

&index( `wholestring', `characterstring')
&Index( `wholestring', `characterstring')

Comments:

  • Delimiting quotes are not included in the character position.
  • &INDEX returns 0 when there is no character string.

Example:

Search for the first occurrence of the character string IS. The value 3 is returned because IS first occurs in the third position.

&INDEX( 'THIS IS AN EXAMPLE', 'IS')
Previous Topic Next topic Print topic