I want to go to a different card of another stack. This works but not always in my script?!

Klaus Major klaus at major-k.de
Thu Oct 16 12:30:18 EDT 2008


Hi William,

> Hello there,
>
> I have a main stack with serveral substacks.
> I call the cardnames (from a substack) with: put the cardnames of
> stack "X" into fld "Y".
> I set up the field as a clickable list with:
> on mouseUp
>  if the hilitedLine is not empty
>  then put the value of the clickline into tData
>  then go card tData of stack "X"
>  end if
> end mouseUp

try this:
on mouseUp
   put the selectedtext of me into st
   if st = empty then
      exit mouseup
   end if
   go cd st of stack "X"
end mouseUp

> This works but only when the cardnames are the same as the card ID's.
> As soon as I change the cardnames change into a name like ' apple' the
> script doesn't work anymore.
> Probably the value of the clickline is related to the card ID's (I  
> guess!).
>
> How do I change this so I can have normal cardnames?
> And I think it's kind a fancy when I use: sheet stack and then go to
> the right card.
> I guess that is impossible?
>
> Thanks in advance!
>
> greetings,
>
> William 'MacSmet' de Smet

Best

Klaus Major
klaus at major-k.de
http://www.major-k.de





More information about the use-livecode mailing list