Regarding: SharePoint PowerApps Customized Forms
PowerApps has a Screen / OnStart event that may be used to populate collections or set variables on load.
I’ve recently discovered an issue, where the OnStart event is triggered only once on the first item a user edits in a SharePoint list. If a user opens a second item OnStart does not trigger.
Behavior:
1. User edits existing form – OnStart is triggered
2. User saves or cancels form
3. User opens new form - OnStart does not trigger – global variables are set to values from previous load
4. User saves or cancels form
5. User opens second existing item – OnStart does not trigger
To recreate the issue spin up a simple list with a few columns, create a PowerApps Customized form for the SharePoint List.
1. Go to OnStart under “…Screen” for the form and create a global variable and set it to Now(): Set(myStartTime , Now())
2. Create a label on the form and set the text property to the start time variable myStartTime
3. Save/Publish
Test:
1. Open the first item or create a new item: Note the date and time
2. Close or Save form
3. Open a second item, the label will have the previous data and time from the last item opened.
2nd Issue:
PowerApps has a ResetForm() function that is called when a PowerApps form is saved or canceled. It initializes controls on the form to default or (current) values of the underlying listitem.
There is an issue with dropdown controls and radio buttons populated from collections. These types of controls will not reset properly and sometimes will display values from the previous item edited.
Has anyone encountered these issues?