Pessoal olha o q eu fiz.... não esta pronto ainda..... estou por enquanto só mostrando os campos nos edits procedure TForm1.Button1Click(Sender: TObject);
var
f : TextFile;
s : string;
lst : TStringList;
begin
AssignFile(f,'C:\teste.txt');
Reset(f);
while not eof(f) do
begin
Readln(f,s);
lst := TStringList.Create;
lst := SeparaString(s);
Edit2.Text := lst.ValueFromIndex[1];
Edit3.Text := lst.ValueFromIndex[2];
end;
end;
function TForm1.SeparaString(Str: String): TStringList;
var
posSol : integer;
retorno : TStringList;
begin
retorno := TStringList.Create;
repeat
posSol := pos(';',Str);
if posSol = 0 then
retorno.Add(Str)
else
begin
retorno.Add(copy(Str,0,posSol-1));
delete(Str, 1, posSol);
end;
until posSol = 0;
result := retorno;
end; mas o problema é que os textos parecem com a primeira letra comida assim o 69930000;ACRELANDIA :M;GERAL;GERAL aparece no edit2 => CRELANDIA :M aparece no edit3 => ERAL por favor me ajudem!!!!