Hi,
I need to change the Displaymode to disabled on a button if an email exists in a certain column on a sharepoint list.
The idea is that it will use Office365Users.MyProfile().mail to get the current users email and look up to see if that email exists in the column. If it exists in the column the it will be Displaymode.Disabled if it doesnt exist then it will be Displaymode.Edit.
Would be greatful for any suggestions.
Thanks!
Solved! Go to Solution.
Hi @CBI_Oshin,
You could just put the following formula on the DisplayMode property of your button control:
If(IsBlank(LookUp(<YourList>,<YourEmailColumn>=Office365Users.MyProfile().mail)), DisplayMode.Edit, DisplayMode.Disabled)
In other words, if an item in your list does note exist with the user's email then the button is active. Otherwise, it is disabled.
Hope this helps. If it does, please consider accepting this post as the solution.
Emmanuel
Hi @CBI_Oshin,
You could just put the following formula on the DisplayMode property of your button control:
If(IsBlank(LookUp(<YourList>,<YourEmailColumn>=Office365Users.MyProfile().mail)), DisplayMode.Edit, DisplayMode.Disabled)
In other words, if an item in your list does note exist with the user's email then the button is active. Otherwise, it is disabled.
Hope this helps. If it does, please consider accepting this post as the solution.
Emmanuel
Thank you this worked!
User | Count |
---|---|
194 | |
126 | |
90 | |
48 | |
44 |
User | Count |
---|---|
280 | |
160 | |
138 | |
81 | |
76 |