curious "go to" behaviour

Jacques Hausser Jacques.Hausser at ie-zea.unil.ch
Thu Apr 29 05:01:01 EDT 2004


Hello everybody

I have a stack with a group of cards named "KF 0" to "KF 67". These 
names are put in an array for retrieving them in a special order 
depending of other operations. The bit of script to go back to these 
cards was as follow:

if bc > 0 then
         go to cd backcarte[bc]
         delete variable backcarte[bc]
         subtract 1 from bc
end if

It works well for every card except card "KF 0" for which it stubbornly 
refuses to go there. I turned the problem by:

if bc > 0 then
         if backcarte[bc] = "KF 0" then
                go to cd "KF 0"
         else
                go to cd backcarte[bc]
         end if
         delete variable backcarte[bc]
         subtract 1 from bc
end if

... and it works! Other scripts of this stack use card names in 
variables (including "KF 0") without problems. It's not a question of 
life and death, but I'm puzzled...

Thank you for any hint!

Jacques


****************************************
*                  new address                      *
****************************************
Prof. J. Hausser
Department of Ecology and Evolution
Biology Building
University of Lausanne
CH-1015 Lausanne-Dorigny
tel: ++ 41 21 692 41 62
fax: ++ 41 21 692 41 65



More information about the use-livecode mailing list