AnsiPos
Locates the position of a substring within a string.
function AnsiPos(const Substr, S: string): Integer;
Description
Call AnsiPos to obtain the byte offset of the Substr parameter, as it appears in the string S. For example, if Substr is the string 'AB', and S is the string 'ABCDE', AnsiPos returns 1. If Substr does not appear in S, AnsiPos returns 0.
Example
if AnsiPos('.', ResultStr) <> 0 then
MessageBox('ResultStr含有.');