delphi之字符串截取

如:000043213000   截取后:432130

delphi 代码:

var ii:integer;

    svalue:varchar(255);

 sPatientId:='000043213000';

sValue := Copy(sPatientId, 1, 10) ;

      for ii:=1 to Length(sValue) do
         begin
           if sValue[ii]<>'0' then
           begin
             Break;
           end;
         end;
    sValue:= Copy(sValue, ii, 10-ii+1);

原文地址:https://www.cnblogs.com/cnajian/p/2367062.html