home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Power-Programmierung
/
CD1.mdf
/
magazine
/
pcmagazi
/
1989
/
05
/
delay.bas
< prev
next >
Wrap
BASIC Source File
|
1989-02-06
|
556b
|
18 lines
Delay.start! = TIMER 'the start of the delay
Duration! = 1.5 'we want to wait 1.5 seconds
CLS
DO
'do any desired tasks
CALL Delay(Delay.start!, Duration!, Time.left!)
LOOP WHILE Time.left! > 0
SUB Delay (Start.time!, Dur!, Secs.left!) STATIC
IF TIMER >= Start.time! THEN 'same day as we started
Secs.left! = Start.time! + Dur! - TIMER
ELSE 'we have passed midnight
Secs.left! = Start.time! + Dur! - TIMER - 86400
END IF
END SUB