|
Pages: [1]
|
 |
|
Author
|
Topic: Greying out buttons (Read 402 times)
|
|
KenSingleton
|
In traditional GUI environments there is usually a simple way to grey out a button when it is not meant to be used and an equally simple way to reveal it so that it can be used. How would one do such a thing in VID?
I know that you can show and hide buttons, but is there a way to hide buttons at the first viewing of a face and then reveal only the buttons as needed through the show word in a button's action block?
The reason I need this is to create a step by step process where the next step can only work when the previous step has been completed. Only at that point should the next button be revealed.
Regards, Ken.
|
|
|
|
|
Logged
|
|
|
|
|
Sunanda
|
Try this: view/new layout [a: button "hello"] hide/show a do-events
The view/new displays the layout but allows the script to continue. The hide adjusts the layout to how you want it (in this case, hiding a button) The do-events drops you into the GUI event loop in the same way that the usual view would do.
|
|
|
|
|
Logged
|
|
|
|
|
KenSingleton
|
Wow! Fastest reply ever, and it works! Thanks, Sunanda, you're a star.
|
|
|
|
|
Logged
|
|
|
|
|
Anton
|
If you want to keep it in spec: view layout [button with [show?: false]]
|
|
|
|
|
Logged
|
|
|
|
|
|
Pages: [1]
|
|
|
 |