
I have a Gallery that Displays a Status Column - which is defined as a 'single line of text'. This column will usually have a number in it.
I would like to increment all items in the Gallery by a specific number. Currently, I have a text Box (UpdateStatus) on the Screen and I can input my number there.
I have inserted a button in the gallery with the Code
Patch('SPlist', ThisItem, {Status:ThisItem.Status+UpdateStatus.Text})
This works, but I have to click the button in each row of the Gallery. Is there a way to do this with a single Click?
You can update them all with the following formula:
ForAll(
yourGallery.AllItems As _item,
UpdateIf('SPlist', ID=_item.ID,
{Status: Status + Value(UpdateStatus.Text)}
)
)
I hope this is helpful for you.