cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Anonymous
Not applicable

Variables prior to load

This seems like a really bad question in my opinion but I could not find any solution online.  Basically I want to set the position and visibility of buttons based on what user is using the app.  I made this work by defining the variables in the OnStart property of the app, however, this shows buttons before they are set to their designated visibilty and position.  The workaround I found was covering the screen with a box until the app is finished changing the variables.  I feel that this is a poor workaround but cannot figure out how to set the variables prior to the app loading.  Any advice or better solution would be greatly appreciated. 

1 ACCEPTED SOLUTION

Accepted Solutions
Super User
Super User

Re: Variables prior to load

@Anonymous 

There are a couple of options you can explore:

 

1) Change the Visible property of the controls to only be visible when certain items are valid in your App.  This can be done in many different ways - a very simple solution (may or may not apply to your scenario) is to move all your buttons to the very top of the screen (Y=0).  Apply your formula for setting the Y value based on the loaded user - if not loaded then set to 0.  Then set the Visible property to !(Y=0) This will return true if the Y value is not 0 and thus be visible.  So...once your formulas adjust the Y value, then your control will be visible.

 

2) Add a Splash Screen to your app that will display until the data you want is loaded and then automatically go to the next/first screen.

 

3) Play with the Delayed Load advanced feature to see if there is any impact on your timing of data loading. (don't know your specifics, so may or may not help)

 

4) Oh I had another one in mind when I was typing the above and now it is gone from my mind...If I think of it again, I'll post back.

 

EDIT: #5 (it's different than what I was thinking with #4 which I still don't recall)

5) Disabled the "non-blocking OnStart rule" in the advanced features to make sure your OnStart completes.

 

I hope some of the above is helpful for you or sparks some ideas.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.

View solution in original post

1 REPLY 1
Super User
Super User

Re: Variables prior to load

@Anonymous 

There are a couple of options you can explore:

 

1) Change the Visible property of the controls to only be visible when certain items are valid in your App.  This can be done in many different ways - a very simple solution (may or may not apply to your scenario) is to move all your buttons to the very top of the screen (Y=0).  Apply your formula for setting the Y value based on the loaded user - if not loaded then set to 0.  Then set the Visible property to !(Y=0) This will return true if the Y value is not 0 and thus be visible.  So...once your formulas adjust the Y value, then your control will be visible.

 

2) Add a Splash Screen to your app that will display until the data you want is loaded and then automatically go to the next/first screen.

 

3) Play with the Delayed Load advanced feature to see if there is any impact on your timing of data loading. (don't know your specifics, so may or may not help)

 

4) Oh I had another one in mind when I was typing the above and now it is gone from my mind...If I think of it again, I'll post back.

 

EDIT: #5 (it's different than what I was thinking with #4 which I still don't recall)

5) Disabled the "non-blocking OnStart rule" in the advanced features to make sure your OnStart completes.

 

I hope some of the above is helpful for you or sparks some ideas.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.

View solution in original post

Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

Top Kudoed Authors
Users Online
Currently online: 344 members 5,608 guests
Please welcome our newest community members: