Hi,
I have Gallery (GallaryReq) that shows pending vacation requests.
How would I go about updating an item using he "Cancel Request" button.
If click on the button next to Item 190, the Status field in the sharePoint list 'Absence Requests' data connection, will get update to "Cancelled"
I
Solved! Go to Solution.
On your OnSelect you can use a formula like this:
Patch('Absence Requests, ThisItem, {status:"Cancelled"})
There are some caveats here...this assumes you are not doing anything in particular with the Items of the Gallery (addcolumns, removecolumns, etc)
Also, not knowing what kind of column your Status column is (the above assumes text).
If it is a Choice column, then you will need to alter to this formula:
Patch('Absence Requests, ThisItem,
{status:
{Value:"Cancelled",
'@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedReference"
}
}
)
I hope that is helpful for you.
On your OnSelect you can use a formula like this:
Patch('Absence Requests, ThisItem, {status:"Cancelled"})
There are some caveats here...this assumes you are not doing anything in particular with the Items of the Gallery (addcolumns, removecolumns, etc)
Also, not knowing what kind of column your Status column is (the above assumes text).
If it is a Choice column, then you will need to alter to this formula:
Patch('Absence Requests, ThisItem,
{status:
{Value:"Cancelled",
'@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedReference"
}
}
)
I hope that is helpful for you.
I have a button in a gallery with the following OnSelect:
Patch(MySharepointDatasource,ThisItem,{NameOfField: SomeValue})
Its text field and worked!!
Thank you very much. It was simpler then what I tried
This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.
Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.
User | Count |
---|---|
209 | |
70 | |
49 | |
48 | |
20 |
User | Count |
---|---|
256 | |
125 | |
84 | |
77 | |
72 |