Topic Path: Symbol Reference > Functions > TextIsSame Function
ContentsIndexHome
PreviousUpNext
TextIsSame Function

Compares strings based on the current locale without case sensitivity.

File
function TextIsSame(
    const A1: string; 
    const A2: string
): Boolean;
Parameters 
Description 
A1 
String value used for the comparision.
 
A2 
String value used for the comparision. 

Boolean - True when the values are the same.

TextIsSame is a Boolean function used to determine if the content of the string in A1 and A2 are the same without case sensitivity. The return value is true if the two strings have the same value, false otherwise. 

TextIsSame isolates the differences between string handling routines on the Windows and .Net platforms, and provides a utility function used throughout the Indy library. 

 

On the .Net platform, TextIsSame uses the built-in Compare method for the string data type to perform the comparision. 

 

On all other platforms, TextIsSame uses the AnsiCompareText function for to perform the comparision. 

Use TextStartsWith to perform a case-insensitive comparision for a substring at the beginning of a string.

Copyright 1993-2006, Chad Z. Hower (aka Kudzu) and the Indy Pit Crew. All rights reserved.
Post feedback to the Indy Docs Newsgroup.