Result = CountString(String$, StringToCount$)Description
Returns the number of occurrences of StringToCount$ found in String$.
String$ The input string to use. StringToCount$ The string to be counted in the input string.
The number of occurrences of 'StringToCount$' found in 'String$'.
The counting is not word based, which means that if the 'StringToCount$' is a part of a word, it will be counted as well, as shown in the following example.
Debug CountString("How many 'ow' contains Bow ?", "ow") ; will display 3