cancel
Showing results for 
Search instead for 
Did you mean: 

Gallery Position/Row-number automaticallly

I use a gallery for temporary collection of production-articles. I need the cumulative sum per article started on the top of the gallery and end with the actual element.

 

I know how to setup a position no. but this is not automatically updated when sorting other way:
http://powerappsguide.com/blog/post/generating-row-numbers

 

positionarticle-no.article-descriptionused qtytotal sum per articlecumulative sum per article
1123Avanilla icecream2102
2234Bstrawberry icecream111
3123Avanilla icecream1103
4123Avanilla icecream4107
5123Avanilla icecream31010

 

the position number/id should be always the number you can see on the screen and it should not matter how to sort the rows.

 

gallery asc-sorted by 'used qty' and automatically actualized position:

positionarticle-no.article-descriptionused qtytotal sum per articlecumulative sum per article
1234Bstrawberry icecream112
2123Avanilla icecream1101
3123Avanilla icecream2103
4123Avanilla icecream3106
5123Avanilla icecream41010

 

and same desc-sorted by 'used qty' and automatically actualized position:

 

positionarticle-no.article-descriptionused qtytotal sum per articlecumulative sum per article
1123Avanilla icecream4104
2123Avanilla icecream3107
3123Avanilla icecream2109
4123Avanilla icecream11010
5234Bstrawberry icecream119
Status: New