Time Counter
Malte Brill
revolution at derbrill.de
Tue Feb 22 04:47:46 EST 2005
Hi Signe,
you might try this script (which can be adapted to split out hours too):
on mouseUp
set the istimer of me to 0
if the flag of me is empty then set the flag of me to -1
set the flag of me to the flag of me*-1
if the flag of me=1 then startMyTimer
end mouseUp
on startMyTimer
set the isTimer of me to the isTimer of me+1
put the isTimer of me div 60 into myMinutes
if myMinutes<10 then put "0"&myMinutes into myMinutes
put the isTimer of me mod 60 into mySeconds
if mySeconds<10 then put "0"&mySeconds into mySeconds
put myminutes&":"&myseconds
if the flag of me=1 then send startMyTimer to me in 1 second
end startMyTimer
Cheers,
Malte
More information about the use-livecode
mailing list