Ver Mensaje Individual
  #4  
Antiguo 04-11-2004
chelejuan chelejuan is offline
Miembro
 
Registrado: nov 2004
Posts: 36
Reputación: 0
chelejuan Va por buen camino
Al final lo he hecho asi, no creo que sea lo mas correcto pero al menos funciona

Cita:

AssignFile(f,Edit3.text);
if fileexists(Edit3.text) then
begin // seguir escribiendo


append(f);
Reset(f);
Readln(f, ch);
a:= ch;

while not EOF(f) do
begin
Readln(f, ch);
a:= ch;
end;

a:=Copy(a,1,29);
a:= copy(a,27,29);
numApunt := strtoint(a);
numApuntiva := strtoint(a);
CloseFile(f); // cerrar el fichero ya que tengo el numero apunte
AssignFile(f,Edit3.text); // esto es para abrir el fichero
append(f); // esto es para continuar escribiendo



end

else

begin // crear archivo
rewrite(f);
numApunt := 1;
numApuntiva := 1;
end;
Responder Con Cita