Código
Segue abaixo a função que eu criei. Espero que ela ajude você no desenvolvimento de seu projeto. Caso você encontre algum erro ou faça alguma melhoria favor me avisar através do e-mail :llutti@hotmail.com}
function Subst(Text,NewChar,OldChar:String):String;
var
Cont : Integer;
begin
if NewChar = OldChar then
begin
Result := Text;
Exit;
end;
cont := Pos(OldChar,Text);
while Cont > 0 do
begin
Delete(Text,Cont,Length(OldChar));
Insert(NewChar,Text,Cont);
cont := Pos(OldChar,Text);
end;
Result := Text;
end;
Planeta Delphi - www.planetadelphi.com.br - Todos os direitos reservados | Copyright 2001-2009