System.SysUtils.AnsiStrPos

From Appmethod Libraries
Jump to: navigation, search

Object Pascal

function AnsiStrPos(Str, SubStr: PAnsiChar): PAnsiChar;
function AnsiStrPos(Str, SubStr: PWideChar): PWideChar;

C++

extern DELPHI_PACKAGE char * __fastcall AnsiStrPos _DEPRECATED_ATTRIBUTE1("Moved to the AnsiStrings unit") (char * Str, char * SubStr)/* overload */;

Properties

Type Visibility Source Unit Parent
function public
System.SysUtils.pas
System.SysUtils.hpp
System.SysUtils System.SysUtils

Description

Warning: Ansi version of AnsiStrPos is deprecated. Please use AnsiStrings unit.

Returns a pointer to the first occurrence of a substring.

Call AnsiStrPos to locate the first occurrence of SubStr in Str. If SubStr does not occur in Str, AnsiStrPos returns nil (Object Pascal) or NULL (C++).

Unlike the StrPos function, AnsiStrPos works with multi-byte characters sets (MBCS).

See Also