
Announcements
Hi,
I have to authenticate user by their roles, previously I used to keep formula in onstart it used to work fine, but since power apps included new feature (i.e startscreen), I am not able to use this formula neither in onstart nor in startscreen both ways it is showing error.
Thanks in advance
Hi @Hemasai1999 :
The point is that StartScreen is a data flow property that can't contain behavior functions.In addition, Global variables and collections, including those created in OnStart, are not available in StartScreen.
I think this link will help you a lot:
You could try to set the app's StartScreen property to:
With(
{varRole:LookUp(XXXXXXX)},
If(
varRole.Role="LP",
'Lp screen',
varRole.Role="Admin",
'Admin screen',
varRole.Role="Trainer",
'Trainer Screen screen',
varRole.Role="LC",
'LC screen',
'No Access screen'
)
)
Best Regards,
Bof