Hello
Hoping someone can give me some advice on how to tackle this problem as I'm new to powerapps and stumped! I'm trying to create a situation where users complete forms from a gallery selection and once they have complete the form have a set amount of time to go back and edit the form from the gallery before it is hidden from view.
My gallery is run off a SP list and to start with I created a field for 'TimerEnd' as a choice column with Yes/No (avoided using y/n field as I understand there are some issues with updating context). The plan was to filter the gallery on the TimerEnd yes/no values by doing the following:
I created a timer on the item screen where the form is and then made the submit button on the item edit form start the timer using 'UpdateContext({Timego:true})' and setting the timer start to 'Timego'. For the OnTimerEnd I used:
'Patch('SP list name', First(Filter('SP list name', ID= 'gallery name'.Selected.ID)),{TimerEnd:{'@odata.type':"#Microsoft.Azure.Connectors.Sharepoint.SPListExpandedReference",Id:1,Value:"Yes").
to hopefully patch the SP list value once the timer ends. The form on submit is set to email a user using O365 Send email and then Refresh and Navigate back to the home screen.
This all seems to work fine, pressing submit starts the timer, the timer ends and as long as I don't navigate away from the form screen the TimeEnd form value changes from No to Yes when the timer ends, however I don't want the user to have to sit and look at the form and want to navigate them back to the home screen while the timer ticks down. I have checked that the timer AutoPause is set to false but for some reason the patch is not updating the SP list value.
Can anyone point out where I have made the mistake or suggest another/better way to filter the gallery to hide items after an amount of time? (I can't use default modified date as admin users set the form up for users)
Thanks in advance for any help anyone can offer!