cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
PowerAppNoob
Helper I
Helper I

Navigate to success screen after submitting the last item in gallery

I have a gallery which i use to populate data in a form. This is what I want to achieve:

PowerAppNoob_1-1613145328775.png

 

1. I select  Item 1 in the gallery.

2. The upper part of form gets populated with data coming from Sharepoint List.

3. User edits the lower part of the form.

4. Once done, user clicks the submit button.

5. Item 1 in the gallery disappears and gallery shows the 'unprocessed items' until all items have been processed and submitted.

6. On the submission of the last item in the gallery, the screen navigates to a SuccessScreen.

 

Steps 1 to 5 are already done. How can I achieve Step 6? Any help would be appreciated.

13 REPLIES 13

@RandyHayes 

Nothing happens. The screen just didn't navigate to the Success Screen even if the gallery and the form are already empty after submitting the last item.

 

PowerAppNoob_0-1613355090971.png

 

PowerAppNoob_1-1613355118239.png

 

 

RandyHayes
Super User
Super User

@PowerAppNoob 

Well, in reality, the Gallery will not have reevaluated it items at the OnSuccess time.

So, if you know that the last item being submitted is the last on the list, then you can also go with this:

If(CountRows(Gallery.AllItems)<2, Navigate(scrSuccess))

 

I have another method in mind, but give this a shot first.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
NOTE: My normal response times will be Mon to Fri from 1 PM to 10 PM UTC (and lots of other times too!)
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!

@RandyHayes 

 

That worked! You're a saviour! But I'm curious why the value has to be <2? I actually tried <1 and it didn't work.

RandyHayes
Super User
Super User

@PowerAppNoob 

Well, it was really just trying to get the value of 1.  But, I decided to not exclude 0.  And so setting it to =1 would not do what was needed in case there was actually 0.

Glad it is working for you now!

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
NOTE: My normal response times will be Mon to Fri from 1 PM to 10 PM UTC (and lots of other times too!)
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

May UG Leader Call Carousel 768x460.png

June User Group Leader Call

Join us on June 28 for our monthly User Group leader call!

PA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.

PA.JPG

New Release Planning Portal (Preview)

Check out our new release planning portal, an interactive way to plan and prepare for upcoming features in Power Platform.

Top Solution Authors
Users online (1,777)