本文整理自网络,侵删。
function StrReplace(s,oldstr,newstr:string):string; //字符串替换varSelPos,SelLen: Integer;beginSelPos := Pos(oldstr, s);while SelPos > 0 dobeginSelLen := Length(oldstr);delete(s,SelPos,SelLen);insert(newstr,s,SelPos);SelPos := Pos(oldstr, s);end;Result:=s;end;
相关阅读 >>
Delphi xe android下让tmemo不自动弹出键盘
更多相关阅读请进入《Delphi》频道 >>