cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Anonymous
Not applicable

Rules - Set Labels Visible - Button to set Invisible

In PowerApps I have rules set-up to make a gallery, rectangle box, and a close button visible once a certain field is selected from a drop-down box.  How do I make these same items invisible onSelect of the close button? 

 

Rules_v1.JPG

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Community Support
Community Support

Re: Rules - Set Labels Visible - Button to set Invisible

Hi @Anonymous,

Do you want to display the overlay box based on the selected value within the Combo Box, and hide the overlay box via clicking the "Close" button?

Have you grouped all controls within the overlay box (Pop-up box) that you mentioned?

Based on the formula that you provided, I think there is something wrong with it. Currently, within PowerApps, we could not assign a value to a property of a control within another control directly.

I have made a test on my side, please take a try with the following workaround:7.JPG

 

8.JPG

I have grouped all controls (Rectangle control, Gallery, button, etc) within Pop-up box (overlay box).

Set the Visible property of the Group1 control to following:

If(ComboBox1.Selected.Value="PowerApps", true, false)

On your side, you should type:

If(DD_ComboBox.Selected.Value = "Gen Info", true, false) 

Within the Pop-up box, set the OnSelect property of the "Close" button to following:

Reset(ComboBox1)

On your side, you should type:

Reset(DD_ComboBox)

Please check the attached GIF screenshot for more details:

 

 

In addition, you could also consider take a try with the following workaround:

Set the OnChange property of your Combo Box (DD_ComboBox) to following:

If(DD_ComboBox.Selected.Value="Gen Info", Set(IsShow, true), Set(IsShow, false))

Set the Visible property of the Close button (Bttn) to following:

IsShow

Set the Visible property of the Gallery7 to following:

IsShow

Set the Visible property of the Rectangle4_1 to following:

IsShow

 Set the Visible property of the Rectangle4 to following:

IsShow

Set the OnSelect property of the "Close" button to following:

Set(IsShow, false)

 

Best regards,

Kris

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

4 REPLIES 4
Highlighted
Resolver I
Resolver I

Re: Rules - Set Labels Visible - Button to set Invisible

Hi @Anonymous,

 

Do you want to the Dropdown Select Items not show in the Gallery?

I have tested by using Collection as next:

20190108test.png

Button_Start.OnSelect: ClearCollect(IceCream, {Flavor: "Strawberry",Quantity:300},{Flavor:"Chocolate",Quantity: 100})

Dropdown1.Items:IceCream.Flavor

Button_Close.OnSelect:ClearCollect(IceCream1,Filter(IceCream, Flavor<>Dropdown1.Selected.Value))

Gallery.Items:IceCream1

 

When clicking the Button_Close, the Dropdown1.Selected.Value will not show in the Gallery.

20190108test1.gif

 

 

Highlighted
Anonymous
Not applicable

Re: Rules - Set Labels Visible - Button to set Invisible

@xyzzyx666 , Yes a drop-down is the initial driver.  Based on what is selected there's a pop-up box (created from with a gallery,button, & rectangle) that overlays another gallery.   It has a close button that I've been working on. 

 I currently have this behind the button OnSelect .    

Concurrent

(
(Bttn.Visible = false),
(Gallery7.Visible = false),
(Rectangle4_1.Visible = false),
(Rectangle4.Visible = false)
)

 

 Also, I need to keep everything behind the overlay message box. 

The drop-down that triggers the overlay box: 

Overlaybox has behind the Visible : If (DD_ComboBox.Selected.Value = "Gen Info",true,false) 

I removed it from the "Rules"  and added the If  to the visible on the Overlaybox controls/labels.  

 

 

Highlighted
Community Support
Community Support

Re: Rules - Set Labels Visible - Button to set Invisible

Hi @Anonymous,

Do you want to display the overlay box based on the selected value within the Combo Box, and hide the overlay box via clicking the "Close" button?

Have you grouped all controls within the overlay box (Pop-up box) that you mentioned?

Based on the formula that you provided, I think there is something wrong with it. Currently, within PowerApps, we could not assign a value to a property of a control within another control directly.

I have made a test on my side, please take a try with the following workaround:7.JPG

 

8.JPG

I have grouped all controls (Rectangle control, Gallery, button, etc) within Pop-up box (overlay box).

Set the Visible property of the Group1 control to following:

If(ComboBox1.Selected.Value="PowerApps", true, false)

On your side, you should type:

If(DD_ComboBox.Selected.Value = "Gen Info", true, false) 

Within the Pop-up box, set the OnSelect property of the "Close" button to following:

Reset(ComboBox1)

On your side, you should type:

Reset(DD_ComboBox)

Please check the attached GIF screenshot for more details:

 

 

In addition, you could also consider take a try with the following workaround:

Set the OnChange property of your Combo Box (DD_ComboBox) to following:

If(DD_ComboBox.Selected.Value="Gen Info", Set(IsShow, true), Set(IsShow, false))

Set the Visible property of the Close button (Bttn) to following:

IsShow

Set the Visible property of the Gallery7 to following:

IsShow

Set the Visible property of the Rectangle4_1 to following:

IsShow

 Set the Visible property of the Rectangle4 to following:

IsShow

Set the OnSelect property of the "Close" button to following:

Set(IsShow, false)

 

Best regards,

Kris

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Highlighted
Anonymous
Not applicable

Re: Rules - Set Labels Visible - Button to set Invisible

@v-xida-msft   Thank you! Smiley Happy   The second solution you suggested using the on-change worked for the App.  

 

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

Watch Now

Experience what’s next for Power Apps

See the latest Power Apps innovations, updates, and demos from the Microsoft Business Applications Launch Event.

Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Solution Authors
Top Kudoed Authors
Users online (7,416)