ReadMe file for StringFns

This is a small Freeware unit which has a few functions which perform functions either missing from Delphi or which were more comfortable for me to use when I went over from Basic to Pascal (a course I recommend) after a blissfully short flirtation with C and C++.

Anyway use them if you like them and don't if you don't.

Brief documentation

To Install just put StringFns.dcu into the Delphi 3\Lib folder and put StringFns in the uses section of any app you want to use it with.


function Instr(str:string;substr:string):integer;
Returns the position in the string of the first instance of a specified substring.

function LeftStr(instring:string;index:integer):String;
Returns the left most 'index' characters of a string.

function RightStr(instring:string;numchars:byte):String;
Returns the right most 'index' characters of a string.

function MidStrToEnd(instring:string;index:integer):string;
Returns the remaining right hand characters of a string from a set index from the left.

function ReplaceStr(str,old,new:string):string;
Returns a string with the 'old' characters replaced by the 'new'.

function StringStripAll(instring,charac:string):string;
Returns a string with all instances of 'charac' removed from anywhere in the string.

function StringStripLeading(instring,charac:string):string;
Returns a string with all leading (at the beginning of the string) instances of 'charac' removed.
function StringStripTrailing(instring,charac:string):string;
Returns a string with all trailing (at the end of the string) instances of 'charac' removed.

That's all.

Comments to me 

Richard Sharpe
5 Camberwell Terrace
Leamington Spa
Warwickshire
CV31 1LP
UK

email: richard@camberwell5.demon.co.uk
