Du musst es unter Type schreiben, z.B.:
Delphi-Quellcode:
type
TForm1 = class(TForm)
procedure delay(msec:longint);
private
{ Private declarations }
public
{ Public declarations }
end;
Und den Code unter implementation z.B.
Delphi-Quellcode:
implementation
procedure TForm1.delay(msec:longint);
var
start,stop:longint;
begin
start := gettickcount;
repeat
stop := gettickcount;
application.processmessages;
until (stop - start ) >= msec;
end;
Frederic H.