cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Rebeccak
Helper III
Helper III

Back Button within the same screen

I have a screen that has multiple controls (mostly buttons). These controls set certain variables to have different galleries and metrics filtered and visible.  I would like to use the back arrow icon on the screen. Once clicked it would set the previous looked at variables.

example:

 

Button1.onselect- UpdateContext({varbackbutton:"1"});Set(vartype,Management)

Back arrow Icon.Default-varbackbutton

BackArrowIcon.Onselect-If(varbackbutton="1",Select(Button1))

 

This works somewhat, i think i need a varcurrentbutton, then onchange,set varbackbutton  or something like that. 

 

I just want to do the last event. Any Ideas?

3 REPLIES 3
PowerAddict
Super User II
Super User II

If you want the back button to do what Button1 does, have you tried using the same OnSelect property for back button as that of button1? I am assuming between clicking on Button1 and the back button, there are other steps the user will take?

Let me know if I am missing any details.

---
If you like this reply, please give kudos. And if this solves your problem, please accept this reply as the solution.

Thanks!
Hardit Bhatia
The Power Addict
https://thepoweraddict.com

Ok. Ill try and explain it a little better. 

User clicks button1 (variables are set, showing different galleries and such)

User clicks button2(variables are set, showing different galleries and such)

User clicks button 3 within a gallery presented by button 2 (shows information regarding item in gallery)

User clicks the back icon goes back to only button2 variables, then clicks back again and button1 variables are displayed.

 

Does that make sense?

"User clicks button 3 within a gallery presented by button 2 (shows information regarding item in gallery)"

Set a variable (say Button3ContentVisible) to true on the OnSelect of Button3. "Information regarding item in gallery" should have their visible property set to Button3ContentVisible.

Now the back button will have an OnSelect property set to:
Set(Button3ContentVisible, false)

Also on the OnVisible property of the screen, set the variable to false so that Button3 content is not visible by default.
Set(Button3ContentVisible, false)

Let me know if that meets your needs.

---
If you like this reply, please give kudos. And if this solves your problem, please accept this reply as the solution.

Thanks!
Hardit Bhatia
The Power Addict
https://thepoweraddict.com




Helpful resources

Announcements
PA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

Power Query PA Forum 768x460.png

Check it out!

Did you know that you can visit the Power Query Forum in Power BI and now Power Apps

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

PowerPlatform 768x460.png

Microsoft Learn

Check out our new Discover Your Career Path blog post series and get all the details.

Users online (1,437)