Delphi Basics
AnsiLowerCase
Function
Change upper case characters in a string to lower case SysUtils unit
 function AnsiLowerCase ( const MixedString : string ) : string;
Description
The AnsiLowerCase function creates a copy of MixedString with all letters converted to lower case.
 
All Ansi commands support multi-byte and accented characters.
Notes
AnsiLowerCase supercedes the LowerCase function.

Multi-byte character sets are operating system defined. For example, Oriental versions of Windows uses multi-byte characters to support their very large set of primitives ('letters').
Related commands
AnsiUpperCase Change lower case characters in a string to upper case
UpCase Convert a Char value to upper case
 
Example code : Converting a mixed case string to lower case
// Full Unit code.
// -----------------------------------------------------------
// You must store this code in a unit called Unit1 with a form
// called Form1 that has an OnCreate event called FormCreate.
 
unit Unit1;
 
interface
 
uses
  SysUtils,   // Unit containing the AnsiLowerCase command
  Forms, Dialogs;
 
type
  TForm1 = class(TForm)
    procedure FormCreate(Sender: TObject);
  end;
 
var
  
Form1: TForm1;
 
implementation
{$R *.dfm} // Include form definitions
 
procedure TForm1.FormCreate(Sender: TObject);

var
  SimpleString : string;

begin
  SimpleString := AnsiLowerCase('The Cat Sat On The MAT');
  ShowMessage('SimpleString : '+SimpleString);
end;
 
end.
Hide full unit code
   SimpleString : the cat sat on the mat
 
 
© CodeGear 2006 - 2007. All rights reserved.  |  Home Page