http://www.netease.com/~cyhan/vcl_files/BASICS.ZIP
这里面有用Delphi 实现的50多个 VB的函数
{+-------------------------------------------------------+}
{: Function : LEFT :}
{+-------------------------------------------------------+}
{: Syntax : LEFT ( <expC> , <expN> ) :}
{: :}
{: where : <expC> = character string :}
{: <expN> = number of characters to return :}
{: Integer value :}
{: :}
{: Action : Returns a specified number of characters :}
{: in the character string <expC>, starting :}
{: from the leftmost character. :}
{: :}
{: Result Type : String :}
{+-------------------------------------------------------+}
Function Left;
begin
Left := Copy(inString,1,numChars)
end;
{+-------------------------------------------------------+}
{: Function : RIGHT :}
{+-------------------------------------------------------+}
{: Syntax : RIGHT ( <expC> , <expN> ) :}
{: :}
{: where : <expC> = character string :}
{: <expN> = number of characters to return :}
{: Integer value :}
{: :}
{: Action : Returns the rightmost <expN> portion of a :}
{: character string <expC> :}
{: :}
{: Result Type : String :}
{+-------------------------------------------------------+}
Function Right;
Var
index : Byte;
begin
If numChars >= Length(inString) then
Right := inString
else
begin
index := Length(inString) - numChars+1;
Right := Copy(inString,index,numChars)
End
end;