Hi there,
I have a variable OnStart of my app which looks up whether the person using the app is on a Dataverse table. If they are, they can do certain things in my app which others can't. This variable is called "IsPriv"; meaning "Is Privileged".
I want to use this variable to ensure that only those where IsPriv = true, can use a toggle control, otherwise they get a Notify message saying that they don't have permissions. Please can someone advise on the code for this?
Many thanks
K.
Solved! Go to Solution.
In the DisplayMode of the Toggle:
If(IsPriv,DisplayMode.Edit,DisplayMode.View)
Then Inside a Label beside or below the Toggle with:
"You cant use a Toggle" in the Text Property.
Then set the Visible of the Label to: IsPriv
If it doesnt work, show the formula for the Variable.
------------
If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.
In the DisplayMode of the Toggle:
If(IsPriv,DisplayMode.Edit,DisplayMode.View)
Then Inside a Label beside or below the Toggle with:
"You cant use a Toggle" in the Text Property.
Then set the Visible of the Label to: IsPriv
If it doesnt work, show the formula for the Variable.
------------
If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.
Thanks - this works.
When the Privileged user now selects the toggle, a pop up appears with a combobox. When they enter a person into this combobox and hit Submit, it adds the Display Name of the person from the combobox to a variable called "LondonDelPerson".
On my patch command (this is a deskbooking app), a column name is 'LDN Desk Reserved For:' - I want this to patch the LondonDelPerson's name if the variable is not blank, otherwise patch the user's name (User().FullName).
Any ideas?
I was trying Text(If(!IsBlank, LondonDelPerson, User().FullName) but get an error?
Thanks
K.