Page 1 of 1
All card
Posted: Tue Jun 12, 2018 5:24 am
by jwtea
Hello everybody,
I got 10 cards and in all of the card i got the same button....
Any idea what code i can type to hide the button from all cards??
I tried this code but it failed....
Code: Select all
On preopencard
hide btn "button" of all cards
end preopencard
Thanks!
Re: All card
Posted: Tue Jun 12, 2018 9:00 am
by jmburnod
Hi,
You may use a preopencard in stack script
Code: Select all
on preopencard
hide btn "button"
end preopencard
If your btn is the same for all cards you may use a group with background behavior.
Best regards
Jean-Marc
Re: All card
Posted: Tue Jun 12, 2018 2:23 pm
by Klaus
Although LC is very english-like, this does not work, you need to use a repeat loop like:
Code: Select all
...
repeat with i = 1 to the num of cds
hide btn "this is a button with a meaningful name, not just BUTTON, pah!" of cd i
end repeat
...
Re: All card
Posted: Tue Jun 12, 2018 4:00 pm
by dunbarx
Do you in fact have individual identical buttons on each card? If so, do what Jean-Marc suggests. You will not regret it, because imagine you wanted to move these buttons, or change their backColor. You would have to do so on each card.
Write back if you do not know how groups work.
Craig Newman