Hola ecfisa yo con otra consulta
el contador esta funcionado ya configure la ventanita, pero el archivo que me tiene que leer lo esta leyendo peri mira esto que se me escapaba, el archivo tiene en la primera linea los números así en este orden..
1 125 0 0 0 0 0 1.00000 0.00000 0.00000 0.0000
ahora bien el numero que me tiene que mostrar es solo el 125 , como hago para que solo me muestre esos caracteres de esa linea en particular, veras que en primer numero es el 1 que ese no debe salir luego hay un espacio y luego el 125 y hay otro espacio, solo donde esta el 125 es que necesito.
acá te agrego ya lo que tengo gracias a tu ayuda, me dirás por favor que debo agragar...?
Código Delphi
[-] unit Unit1;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, ExtCtrls, StdCtrls;
type
TForm1 = class(TForm)
Timer1: TTimer; StaticText1: TStaticText;
Label1: TLabel; procedure FormCreate(Sender: TObject);
procedure Timer1Timer(Sender: TObject);
private
public
end;
var
Form1: TForm1;
implementation {$R *.dfm}
const
RTA_ARCH = 'C:\DBA\contar.txt';
procedure TForm1.FormCreate(Sender: TObject);
begin
Timer1.Enabled := False;
with TStringList.Create do
try
try
LoadFromFile(RTA_ARCH);
StaticText1.AutoSize := False;
StaticText1.Caption := Strings[Count-1];
StaticText1.BevelKind:= bkTile;
Timer1.Interval := 100;
Timer1.Enabled := True;
except
raise Exception.Create('Error: No se encontró el archivo ' + RTA_ARCH);
end;
finally
Free;
end;
end;
procedure TForm1.Timer1Timer(Sender: TObject);
begin
with TStringList.Create do
try
LoadFromFile(RTA_ARCH);
StaticText1.Caption:= Strings[Count-1];
finally
Free;
end;
end;
end.
....