Bug? Using random number in AppleScript DE-1.6 in Mac OS DE-9.1
Bug? Using random number in AppleScript DE-1.6 in Mac OS DE-9.1
- Subject: Bug? Using random number in AppleScript DE-1.6 in Mac OS DE-9.1
- From: ThK <email@hidden>
- Date: Fri, 29 Jun 2001 00:35:28 +0200
The following script creates an endless loop:
-------------------------
repeat
set tResultList to {}
repeat 100 times
set AutoListe to {{car:"0", Zeit:"60"}, {car:"1", Zeit:"65"}, {car:"2", Zeit:"70"}, {car:"3", Zeit:"75"}, {car:"4", Zeit:"80"}, {car:"5", Zeit:"90"}, {car:"6", Zeit:"95"}, {car:"7", Zeit:"100"}, {car:"8", Zeit:"105"}, {car:"9", Zeit:"110"}, {car:"10", Zeit:"115"}, {car:"11", Zeit:"120"}}
set randomNumber to (random number from 1 to 11)
set RandomCar to item randomNumber of AutoListe
set Countdown to (Zeit of RandomCar)
set tResultList to (tResultList & return & Countdown) as text
end repeat
-- FB Search Scripting Addition:
set t60 to FB Search for "60" in tResultList returning the linecount
set t65 to FB Search for "65" in tResultList returning the linecount
set t70 to FB Search for "70" in tResultList returning the linecount
set t75 to FB Search for "75" in tResultList returning the linecount
set t80 to FB Search for "80" in tResultList returning the linecount
set t85 to FB Search for "85" in tResultList returning the linecount
set t90 to FB Search for "90" in tResultList returning the linecount
set t95 to FB Search for "95" in tResultList returning the linecount
set t100 to FB Search for "100" in tResultList returning the linecount
set t105 to FB Search for "105" in tResultList returning the linecount
set t110 to FB Search for "110" in tResultList returning the linecount
set t115 to FB Search for "115" in tResultList returning the linecount
set t120 to FB Search for "120" in tResultList returning the linecount
set tResList to {t60, t65, t70, t75, t80, t85, t90, t95, t100, t115, t120}
if item 6 of tResList 0 or item 11 of tResList 0 then exit repeat -- This never happens!!!
end repeat
-------------------------
Chris, what9s up with this9???
Thomas
____________________________________________________
"Experience leads to realization,
realization is beyond knowledge,
wisdom beyond experience."
____________________________________________________
"Erfahrung bringt Erkenntnis,
Erkenntnis liegt jenseits des Wissens,
Weisheit jenseits der Erfahrung"
____________________________________________________
Thomas Johannes Matthias Kuehner
Consulter
Trainer
Developer
Administrator
Webmaster
<email@hidden>
<www.macgix.com>
<www.macgix.de>
AppleScript Support in Deutsch <www.ScriptMyMac.de>