Difference between revisions of "TrimOthers"

From SCAR Divi Manual
Jump to: navigation, search
(Created page with "==Definition== <source lang="scar" lines="false"> function TrimOthers(Text: AnsiString): AnsiString; </source> ==Availability== SCAR Divi 3.00 > Current ==Description== Removes...")
 
Line 1: Line 1:
 
==Definition==
 
==Definition==
 
<source lang="scar" lines="false">
 
<source lang="scar" lines="false">
function TrimOthers(Text: AnsiString): AnsiString;
+
function TrimOthers(Str: AnsiString): AnsiString;
 
</source>
 
</source>
  
Line 8: Line 8:
  
 
==Description==
 
==Description==
Removes all characters that are not numbers or letters from a [[AnsiString|string]] '''Text''' and returns it.
+
Removes all characters that are not numbers or letters from a [[AnsiString|string]] '''Str''' and returns it.
  
 
==Example==
 
==Example==

Revision as of 16:23, 17 September 2011

Definition

function TrimOthers(Str: AnsiString): AnsiString;

Availability

SCAR Divi 3.00 > Current

Description

Removes all characters that are not numbers or letters from a string Str and returns it.

Example

begin
  WriteLn(TrimOthers('-Hello World!-'));
end.

Output:

HelloWorld

See Also