cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Gabe140
New Member

Need help to use ForALL to duplicate records and patch into Excel

Hello I am creating an app to use so when people put in a certain amount of tickets into a basket it duplicates their name the amount of times they have on the label into that specific basket excel sheet so I can randomly pick from that excel table later. My issue is how do I go about using ForALL to create the loop and duplicate their record x amount of times they have for that basket? Don't mind the instructions I need to fix the graphics.

 

Screenshot_1.png

1 ACCEPTED SOLUTION

Accepted Solutions
RandyHayes
Super User
Super User

@Gabe140 

You can make use of the Sequence function to create a table of sequential values.

So, for example:

   ForAll(Sequence(yourValue), <do something here>)

Will produce an execution of the <do something here> for the amount of values in your yourValue.

 

I hope this is helpful for you.

_____________________________________________________________________________________
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!

View solution in original post

1 REPLY 1
RandyHayes
Super User
Super User

@Gabe140 

You can make use of the Sequence function to create a table of sequential values.

So, for example:

   ForAll(Sequence(yourValue), <do something here>)

Will produce an execution of the <do something here> for the amount of values in your yourValue.

 

I hope this is helpful for you.

_____________________________________________________________________________________
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
Ignite 2022

WHAT’S NEXT AT MICROSOFT IGNITE 2022

Explore the latest innovations, learn from product experts and partners, level up your skillset, and create connections from around the world.

Power Apps Africa Challenge 2022

Power Apps Africa Challenge

Your chance to join an engaging competition of Power Platform enthusiasts.

Users online (1,339)