Showing results for 
Search instead for 
Did you mean: 
Not applicable

Alternating Items

Just thought I would throw this out there for anyone else stuggling to do something with alternating row colours or positioning.. By default there does not seem to be a OOTB way to get the RowID of a collection of items. To get around this (and this only works if you have an exisitng ID / unique field) when OnVisible event, or the data load event (OnSelect) is triggered  I get my collection of items and then loop through with a ForAll and build a new collection of RowIDs with a reference to the source ID column. Then on my gallery I add a label and do a Lookup to the collection od RowIDs filtered by ThisItem.ID (or whatever your unique field is)


ClearCollect(colData, Filter(Table, 'Created By'.Email = User().Email));
ForAll(colData, Collect(colRowIDs,{colID: ID, rowID: CountRows(colRowIDs) + 1}))

Alternating Rows.PNGTimeline.PNG


Hope this helps.. 🙂

Super User
Super User

Nice! Thanks for sharing this @Anonymous 🙂

Helpful resources

UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Top Solution Authors
Top Kudoed Authors
Users online (2,574)