System.SysUtils.StrLComp

De RAD Studio API Documentation
Aller à : navigation, rechercher

Delphi

function StrLComp(const Str1, Str2: MarshaledAString; MaxLen: Cardinal): Integer; overload;
function StrLComp(const Str1, Str2: PWideChar; MaxLen: Cardinal): Integer;

C++

extern DELPHI_PACKAGE int __fastcall StrLComp _DEPRECATED_ATTRIBUTE1("Moved to the AnsiStrings unit") (const char * Str1, const char * Str2, unsigned MaxLen)/* overload */;

Propriétés

Type Visibilité  Source Unité  Parent
function public
System.SysUtils.pas
System.SysUtils.hpp
System.SysUtils System.SysUtils

Description

Avertissement : La version ANSI de StrLComp est obsolète. Veuillez utiliser l’unité AnsiStrings.

Compare dans deux chaînes un nombre de caractères au plus égal à un maximum spécifié.

StrLComp compare Str1 à Str2, jusqu'à la longueur maximum de MaxLen caractères. La valeur renvoyée est indiquée dans le tableau suivant :



Valeur renvoyée Condition

<0

Str1 avant Str2

=0

Str1 identique à Str2

>0

Str1 après Str2



Remarque :  Lorsque vous utilisez des caractères internationaux, servez-vous plutôt de AnsiStrLComp.

Voir aussi