相当于vb中的right()函数功能在delphi中是什么函数

解决方案 »

  1.   

    修改:copy(str,i,length(str)-i+1);
      

  2.   

    uses StrUtils;function LeftStr(const AText: string; const ACount: Integer): string;
    function RightStr(const AText: string; const ACount: Integer): string;
    function MidStr(const AText: string; const AStart, ACount: Integer): string;
      

  3.   

    楼上的RightStr()函数可用!
    我自己写了一个扩充了一下的函数
    function RightCopy(S: string; Index,count:Integer): string; //从右第Index位复制Count个字符
    begin
      RightCopy := copy(S,Length(S)-count+1-(Index-1),count);
    end;例:
    RightCopy(abcdefghijklmnopqrst,5,3)
    返回nop