0
Good night,
I have a text file with several lines, where the lines that interest me are those that start with 'PU' and 'PD' where within these lines there are values that I would like to assign to two variables.
PW0.350,6;
PW0.350,7;
PW0.350,8;
LT;
SP1;
PU-3651 -2229;
PD-2851 -2229;
PD-2851 -1429;
PD-3651 -1429;
PD-3651 -2229;
SP0;
for example the first line that interests me 'PU-3651 -2229' would like to save (-3651 in variable x and -2229 in y) someone could help me
NOTE: I am already opening the file
if OpenDialog1.Execute then
begin
linhasarq := opendialog1.FileName;
AssignFile(arquivo,opendialog1.FileName);
Memo1.Text := opendialog1.FileName;
reset(arquivo);
while Not (Eof(arquivo)) do
Begin
ReadLn(arquivo,linhasarq);
Memo2.Lines.Add(linhasarq);
end;
CloseFile(arquivo);
I’ve now used the command
– Guilhermeths