How to use Edit Icon only let the designated person modify DataCardValue?
I just want the edit icon that only my or other assgin user can make modifications in other DataCardValue.
For this kind of stuff i usually put in the "Onstart" property of the App a variable where i store with the office365 connector data of the current User (example "varUserProfile").
After that i compare one of the data that I got (most of the time I go for the e-mail comparison) with the e-mail of the people that got the permissions to use it and i store the true/false in another variable (for example "varAdminPermission").
After that I apply to the visible properties of the items where you need permission, you just need to put the "varAdminPermission" and if it's true they can see it.
1-Check current User profile data and store it (varUserProfile)
2-Compare something like varUserProfile.Maill with e-mail that you chose and store in a variable true/false (varAdminPermission)
3-Set the visibile properties of the items: varAdminPermission
Hope it helps,
I tried to use :
the command It's not implemented. It's still available for anyone to edit.
I mean, of course it's available for anyone, becouse with this formula you set only 2 variables without any condition.
If you were following what i said in the last comment, you need to work in "Visible" property of every single item that you want to manage with the Admin permission, and you don't need to set the variable another time, you can just go with the name of the variable, that will put Visible=true or visible=false, based on the first comparison that you already done on the "OnStart" of the app.
I guess you need an example, try like this, that's the code.
The only thing you need to do before is add in the data section the Office 365 connector, so you can take office 365 data.
App - OnStart
//After write the first set run the on start of the app, or set it for the first time with a button, you need it to see the ".Mail" after the variable name the next step
If(varUserProfile.Mail = "email@example.com", Set(varAdminPermission, true));
Random Icon - Visible
@Bob_Yang0030 wait, you are trying to use it in edit mode, and i guess you put the Admin permission on you. I mean, while writing the code for you i tryed it and was working. Just put a random e-mail in the app start and run it another time, and watch if you can see the icon. The best way it's try to use the app normally with 2 account, one with permission and one no. So you can check if they can use the icon.
If you want to stop people modify the app it's another thing and I guess the only way here is to manage the app permission outside. If i have access to the edit mode of the app i can change what i want, there is no way to stop it I suppose.
@Bob_Yang0030 When you share the app you can chose 2 role.
User or Co-owner. user can only use the app, Co-Owner can change all (the only limitation i think is that he can't delete the App).
Explore the latest innovations, learn from product experts and partners, level up your skillset, and create connections from around the world.
Your chance to join an engaging competition of Power Platform enthusiasts.
The Super User program for 2022 - Season 2 has kicked off!
Attend in person or online, there are incredible conferences and events happening all throughout the month of September.