web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Conditionally Navigati...
Power Apps
Answered

Conditionally Navigating through Screens

(0) ShareShare
ReportReport
Posted on by 526

I'm creating something similar to a "checkout" process and need major help on the navigation logic.

 

Right now I have 3 checkboxes (could be up to 20 in the future) that represent services. When the user chooses 1 or more checkboxes, it updates an indicator in a collection. When the user chooses to start the checkout process, they should navigate to the first screen that has "yes" as an indicator. After the user is done with that screen, they should then navigate to the next screen with a "yes" or if there isn't one, then they should end on the final screen.

 

Below is what I've built so far. If you see any flaws in the design, please let me know. I really need help on the navigation logic. I've been scratching my head the past couple of days and nothing has worked.

 

navigation ss1.png

Categories:
  • Verified answer
    Community Power Platform Member Profile Picture
    Microsoft Employee on at

    First, you'll need to collect the values and which screen they are related to. you can do that this way:

    Collect(NavigationCollection,
    {Naviagte:Checkbox1.Value,Screen:Screen1},
    {Naviagte:Checkbox2.Value,Screen:Screen2},
    {Naviagte:Checkbox3.Value,Screen:Screen3},
    ...
    {Naviagte:Checkbox20.Value,Screen:Screen20}
    )

    Then, you can navigate through those by doing this on the "Next" button's OnSelect property: 

    UpdateIf(NavigationCollection,Screen=App.ActiveScreen,{Navigate:false,Screen:App.ActiveScreen});
    Navigate(LookUp(NavigationCollection,Navigate=true,Screen)

     This sets the navigate column to false for that screen then takes to user to the next screen.

  • kriggo15 Profile Picture
    526 on at

    This works perfectly but I have one followup question before I close it out. How would I modify what you posted to end on say "Screen21" once there aren't any more screens set as true?

     

    Basically when I get to the end of the loop, I want the Next button to take me to the last screen (Screen21).

     

    Example 1: Screen2 is the only one set as true so the Next button on Screen2 would take me to Screen 21.

    Example 2: Screen2 and Screen3 are true, so the Next button on Screen2 would take me to Screen 3, and the Next button on Screen3 would take me to Screen 21.

     

    Thanks again and I appreciate your help!

     

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    All you would change is the Navigate function in my example above:

    Set(NextScreen,LookUp(NavigationCollection,Navigate=true,Screen));
    Navigate(If(IsBlank(NextScreen),Screen21,NextScreen)

    ---
    If this answered your question, please click "Accept Solution". If this helped, please Thumbs Up. 

  • kriggo15 Profile Picture
    526 on at

    Thank you, much appreciated.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 352 Super User 2026 Season 2

#2
M Bilal Khan Profile Picture

M Bilal Khan 323

#3
Mohsin Ali Profile Picture

Mohsin Ali 226

Last 30 days Overall leaderboard