cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
vnguyen
Frequent Visitor

OnStart does not work consistently

Hi all, 

 

I have played around with Powerapps recently to create an app for my company. I want my app to automatically create a UniqClient collection whenever the app is lauched. The UniqClient will contain a list of client names who have done business before. However, I do not want to have the repeated name of client as that client may have multiple projects with us. 

 

I have tried to put this following formula ClearCollect(UniqClient,Distinct(TableTesting_1,Clients)) into OnStart. It works but not consistently on the Edit mode. However, it doesn't work at all whenever I actually play my app.  I know the collection is created but with an empty list even though I have close/re-open the app. 

 

Do you know if there is solution for this issue? Any suggestion or workaround? I know OnVisible works, but I still want to create a collection as the app starts and ready to go, rather than switch between the screens to make my app work. 

 

Thanks, 

 

 

4 REPLIES 4
Shanescows
Super User
Super User

https://powerapps.microsoft.com/en-us/blog/performance-considerations-with-powerapps/

 

At the bottom of that article he walks through how to use a Timer Control to do what I believe you want to do. 

Shane - Microsoft MVP, YouTube, and PowerApps Consulting for when you are in a bind to get this fixed quickly. And finally we now have PowerApps Training

Hi Shane, 

 

Thank you for sharing an interesting tutorial. I just incorporated the timer control and "splash screen" to my app. Now my collection is created under the preview mode, but not under Edit or Play app modes. In addition, I have set the duration of timer down to 0.001 but it's not fast enough in order for the user dont see the transition from splash screen to my browsescreen.  Am I missing something ? 

I think you would want to make it so your splash screen sits there, maybe show them an animated loading, while the collection is built. Then when it is done jump to the actual work screen. 

Shane - Microsoft MVP, YouTube, and PowerApps Consulting for when you are in a bind to get this fixed quickly. And finally we now have PowerApps Training

Hi Shane, 

 

I actually created a "Welcome" page earlier. So it works for me in the Preview Mode but not on actual app. Do you have any idea why and how do I fix it? 

 

Thanks  

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Top Solution Authors
Top Kudoed Authors
Users online (2,245)