Goodday, Ive got a simple question
I have an App with different tiles and I want to set the visible property based on different emailadresses but it doesn't seem to work.
In the APP in the OnStart function i've set a variable Set(varUserEmail; User().Email)
And on the tiles I set the visible property to this formula
varUserEmail=("Email")
Or varUserEmail =("Email")
Or varUserEmail =("Email")
Or varUserEmail =("Email")
Basically when I set the visible to a single emailadres is works but when I add more then 1 email everyone sees everything
Solved! Go to Solution.
Yes, that visible property is not valid.
You need to perform a logical function.
Your formula on the Visible should be: varUserEmail in varProjectTeamA & varProjectTeamB
In the above, the two variables are concatenated together (as they are text strings), then the in operator will return true or false if the varUserEmail text is in the concatenated text.
Use in Visible:
If(Or(User().Email = "example1@xyz.com",User().Email = "example2.xyz.com"),true,false)
I'd recommend putting your email addresses in a variable in your OnStart rather than directly in the formula as it will be far simpler to alter that list of emails from one place rather than multiple places.
So, in your OnStart - add: Set(varEmails, "xxxx@mail.com; yyyy@mail.com; zzzz@mail.com" )
Then for your visible property:
varUserEmail in varEmails
The above is all you need in the visible to set it to be visible if the user is in the email list.
I hope this is helpful for you.
@RandyHayes that was my second question so I've skipped step 1 and now i'm going to step 2
Ive done the things that you have said, in this case I've added a variabel, two actually, for Projectteam A and Projectteam B (inc emailadresses) but when I set the visible property on the tiles there is an error which says that it's expecting a true/false and the tile remains invisible
Ive set the visibilty to varProjecTeamA and it returns the blue line
The formula provided is correct and will return a true or false already.
If it is not, then there is something not defined properly with your variables.
Can you provide your current formula for the OnStart for setting the variables as well as the current formula you have in the Visible property (I assume you changed it as you are now including two variables).
This is the formula in the OnStart option
Set(varProjectTeamA;"Email1;Email2.;Email3");;
Set(varProjectTeamB;"Email1;Email2.;Email3")
The visible property on a specific tile is set to simply varProjectTeamA or varProjectTeamB
Yes, that visible property is not valid.
You need to perform a logical function.
Your formula on the Visible should be: varUserEmail in varProjectTeamA & varProjectTeamB
In the above, the two variables are concatenated together (as they are text strings), then the in operator will return true or false if the varUserEmail text is in the concatenated text.
User | Count |
---|---|
247 | |
106 | |
82 | |
50 | |
43 |