I made stack and card inside it. the card has many fields. I need hide some fields and show it in certain event.
I write code
preOpenStack
hide field "t98"
end preOpenStack
But still t98 appears
What do I do?
Hide field on preopenstack
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
-
- Livecode Opensource Backer
- Posts: 10094
- Joined: Fri Feb 19, 2010 10:17 am
Re: Hide field on preopenstack
Um . . .
try this in the card script:
on preOpenCard
hide fld "t98"
end preOpenCard
it works!
try this in the card script:
on preOpenCard
hide fld "t98"
end preOpenCard
it works!
Re: Hide field on preopenstack
Hi.
What Richmond said, and the reason is that the preOpenStack message fires before the card loads. So it is more prudent to put your handler in a place where it is comfortable.
Craig Newman
What Richmond said, and the reason is that the preOpenStack message fires before the card loads. So it is more prudent to put your handler in a place where it is comfortable.
Craig Newman
Re: Hide field on preopenstack
Thanks all
It is working
It is working
Re: Hide field on preopenstack
Hi Ali,
you forgot the highly important ON in your first script:
This way, the "preopenstack" message does NOT get triggered at all!
Best
Klaus
you forgot the highly important ON in your first script:
Code: Select all
preOpenStack
hide field "t98"
end preOpenStack
Code: Select all
ON preOpenStack
hide field "t98"
end preOpenStack
Klaus