I have a very large SharePoint list into which I create items on one screen, and that is bound to a gallery on another screen in the app. I don't want the gallery to update when I insert an item in the datasource, because this slows down the create items, and I need it to be as fast as possible. I was thinking that I could have a separate datasource for the create/update action and another for the list/search function. Is that feasible ? The first solution would have been to copy the datasource to a collection and then bind that collection to the gallery, but the size of the list is too large for this to work. I'm ok with taking a small performance hit when the user goes to the list screen, because then I will need to do a refresh, but I want the insert/updates to be blazing fast (based on a barcode scan).
Any suggestions ?
You can use the same list even though it is large provided that you use delegatable functions. ref. https://powerapps.microsoft.com/en-us/blog/sharepoint-delegation-improvements/ and Shane Young's video on this topic
If possible, I would strive for that as it is by far the simplest and most robust way to make an app.
I understand the principle of delegation, I just don't want to wait for the gallery to refresh on the other screen when i insert an item. If I remove the list screen from the app, the insert is much faster, even when using delegation.
For entering new data, you could have a Save button that Patches the data in the form to a collection instead of submitting it to the datasource and then resets the form. In the OnVisible property of the screen have NewForm(yourForm) and in the OnHidden property of the screen, you could Collect(datasource, coldatasource); Clear(coldatasource). This would allow you to rapidly add new items and update the datasource when you are done and leave the edit screen. You would have to make sure that the user did not quit before leaving the edit screen or the data in the collection would be lost before it could be entered into the datasource.
Yes, it's that last part that is troublesome. I want to be sure that if an item is scanned, it is safely stored in sharepoint. Maybe I just need to remove the list function alltogether, unless I can have it linked to its own datasource - pointing at the same list on sharepoint.
Can somebody confirm if yes or no you can have two datasources pointing at the same sharepoint list and any possible drawbacks or limitations ?
Learn how to create your own user groups today!
Please join us on Wednesday, January 19th, at 8a PDT. Come and learn from our amazing speakers!
Check out the new Power Platform Community Connections gallery!