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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / incremental counting i...
Power Apps
Unanswered

incremental counting in powerapps forms?

(0) ShareShare
ReportReport
Posted on by

Hi, has anyone got code for doing an incremental count within a powerapps form?

I am trying to code a add/remove function for users to e.g. add a guest's details to a form.

Repeating Tables is turning out to be very cumbersome, particularly saving data to SP.

So i'm trying to have 10 hidden rows that get 'shown' when the 'add guest' button is clicked. Hence the need for a count.

Any suggestions would be much appreciated,

Thank you

I have the same question (0)
  • ScottDurow Profile Picture
    1,039 on at

    You might want to look at Sequence - this would allow you to add an index to the new rows:

    Collect(colItems,
     ForAll(Sequence(10),{index:Value,name:"New Row"})
    );
  • Community Power Platform Member Profile Picture
    on at

    Hi Scott, I'm new to Powerapps so if you could please bear with me. 

    ms says 'Sequence' generates a single column table. I have existing rows that are not visible. my idea was to generate numbers i.e. when the user clicks on the 'Add guest' button that and global variable/index would increment to '1'. My first hidden field would have conditional visibility, only becoming visible when variable = '1'.

    and for 'remove guest' index would minus '1'.

  • ScottDurow Profile Picture
    1,039 on at

    We were all new to Powerapps at one point!

    Normally you wouldn't have hidden rows - you would just use Collect to add rows as you need them - is this something you've tried?

  • Community Power Platform Member Profile Picture
    on at

    Have not tried it yet Scott, willing to try.

    Do i create a row with the 3 input fields I need, then inside this add the 'Add guest' button?

    and on the 'Add guest' button property of 'onSelect' do i add the code you mentioned prior?

    Thanks in advance!

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 721 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 320 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard