cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
vish_p
Helper V
Helper V

Loading Screen for users while my form fetches data from Sharepoint list

I am facing an issue when trying to implement loadingscreen in my app to make user aware that my app is fetching data from splist

I have a display form(splist) in my app and one column of that form has some kind of logic in Items property which tries to fetch attachment from another record using Lookup.

Now i have tried to acheive that  : 

  • by trying to collect all the records from my list when screen loads and then display faster results -> in this case i am facing attachment issue
  • by trying to add Updatecontext/Set for the visibilty of my loading screen in the lookup formula i have used in the items property of this column but that is also throwing me errors.

Screenshot attached for referance : 

err.jpg

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
v-xida-msft
Community Support
Community Support

Hi @vish_p,

Do you want to create a Pre-loader screen within your app?

Do you want to set the loading screen on the basis of the time it takes PowerApps to fetch details from SPList?

I have made a test on my side, please take a try with the following workaround:

Set the OnVisible property of the Display form to following:

Set(loading1, true);
Set(
FetchedItems,
LookUp('PO list', customid = BrowserGallery1.Selected.ID_x0020_to_x0020_which_x0020_PO).'{Attachments}'
); Set(loading1, false)

Set the Items property of the specific column in your Display form to following:

FetchedItems

More details about creating a pre-loader screen in PowerApps, please check the following blog:

https://powerapps.microsoft.com/en-us/blog/ux-patterns/

Note: If your LookUp formula executed fastly, you may not see the Pre-loader screen clearly (may be just a flash).

 

Best regards,

Kris

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

6 REPLIES 6
iAm_ManCat
Super User
Super User

Hi @vish_p

 

You can't use 'actions' (behaviours) within the Items property of this object, as it is looking for a specific type of formula to evaluate what items to bring in. Additionally you are using && which is for adding things together such as text or numbers, not behaviours.

 

If you are intending to have these items show up only once loaded, you should try think of it in other ways:

 

Before that list populates via the Lookup - does the user click on something and could I use the OnSelect to do the loading function?
Could I implement the loading screen using a set timer (let's say 5 seconds?) that would wait 5 seconds before displaying the rest of the screen?
Could I have a screen-sized loading page and then have it's onVisible depend on the CountRows of a gallery when clicked?

 

I would suggest in this case to have a pseudo-loading screen, i.e when the user chooses/clicks an item, have the loading screen set to visible, start a timer, and then OnTimerEnd have it set the visible to false and reset the timer - give it a value that is a reasonable amount of time for the user to wait and have a text item on the load screen that says "Load times may vary, please wait..".

 

Cheers,

@iAm_ManCat

 

@iAm_ManCat


Please 'Mark as Solution' if someone's post answered your question and always 'Thumbs Up' the posts you like or that helped you!


Thanks!
You and everyone else in the community make it the awesome and welcoming place it is, keep your questions coming and make sure to 'like' anything that makes you 'Appy
Sancho Harker, MVP


Thanks for response @iAm_ManCat

Solution using timer seems to work here but the issue is as the list keeps on populating,the load time may vary so i can't use a timer,which may make user wait for either shorter time (before all the data is loaded) or longer time (even after all the datas are loaded) both these cases are not user friendly

 

Since its just a display form there is nothing to click here as soon as user is navigated to this screen

 

Can i set the loading screen on the basis of the time it takes powerapp to fetch details from SPList ? any way to track it down ?

v-xida-msft
Community Support
Community Support

Hi @vish_p,

Do you want to create a Pre-loader screen within your app?

Do you want to set the loading screen on the basis of the time it takes PowerApps to fetch details from SPList?

I have made a test on my side, please take a try with the following workaround:

Set the OnVisible property of the Display form to following:

Set(loading1, true);
Set(
FetchedItems,
LookUp('PO list', customid = BrowserGallery1.Selected.ID_x0020_to_x0020_which_x0020_PO).'{Attachments}'
); Set(loading1, false)

Set the Items property of the specific column in your Display form to following:

FetchedItems

More details about creating a pre-loader screen in PowerApps, please check the following blog:

https://powerapps.microsoft.com/en-us/blog/ux-patterns/

Note: If your LookUp formula executed fastly, you may not see the Pre-loader screen clearly (may be just a flash).

 

Best regards,

Kris

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Thanks @v-xida-msft this worked like a charm ! 🙂

Hi what is i dont want to use the lookup, as i have error with lookup, can i just pass my SPList name ? if so how ?

 

Hi @v-xida-msft  what is the look up function duing? I have the same scenario but with a SQL Table. The Gallery may have up to 100 Item and it takes time to load and want to make something more visual than the dots at the top.

Thanks!

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

Users online (5,395)