Page 1 of 1

How to show a button in a hidden group

Posted: Thu Jan 15, 2009 9:30 pm
by mpcard
Hello everyone-

I have an application I am building where I have a large group of buttons. When I switch tabs on my application, I want to hide this group of buttons but later depending on user action make 2 of the buttons visible. My script seems to be working OK but the command to show the buttons that are part of the hidden group does not work, the buttons remain invisible:

on menuPick pItemName
switch pItemName
case "Filter Criteria"
show group "SummaryGroup1"
hide group "AllFilterGroups" // big group of buttons
hide button "RunButton"
show button "FieldMenu1" // button in big group that was just hidden
show button "OpMenu1" // button in big group that was just hidden
show button "RunButton"
break
case "Results"
set the visible of group "SummaryGroup1" to false
set the visible of group "AllFilterGroups" to false
hide button "RunButton"
break
end switch
end menuPick

Any ideas on what I should do? Is it possible to "show" a member of a "hidden" group?

-Mike

Posted: Thu Jan 15, 2009 10:42 pm
by Mark
Hi mpcard,

Just hide all buttons (or all controls, even) of your group and show the buttons you need.

Code: Select all

show grp "Your Group"
repeat with x = 1 to number of buttons of grp "Your Group"
  hide btn x of grp "Your Group"
end repeat
-- blabla here
show btn "The button you want to show"
Best,

Mark