FindString()

语法

Position = FindString(String$, StringToFind$ [, StartPosition [, Mode]])
概要
Find the 'StringToFind$' within the given 'String$'.

参数

String$ The string to use.
StringToFind$ The string to find.
StartPosition (optional) The start position to begin the search. The first valid character index is 1. If this parameter isn't specified, the whole string is searched.
Mode (optional) It can be one of the following values:
  #PB_String_CaseSensitive: case sensitive search (a=a) (default).
  #PB_String_NoCase       : case insensitive search (A=a).

返回值

Returns the position (in character) of the string to find, or zero is the string isn't found. The first character index is 1.
  Debug FindString("PureBasic", "Bas") ; will display 5

已支持操作系统

所有

<- CountString() - String Index - Hex() ->