Hello All,
I can find 99 Percent of my answers here in the forum without posting, so thank you all for that. However, I'm a bit stumped.
I'm trying to Pin favorite record values to the top of the Sharepoint List Gallery for easy access. So, that part is not the problem. The problem is that each User will have his/her own favorites, so I need to be able to store that information somewhere. I'm using a checkbox to get a true/false from the user, and Patching the value to a Column unique to each user. So, it all works when there is just one user, but when I use Switch to change the User_Favorite column name, the Patch isn't sucessful.
This is the Patch Command for OnCheck
Patch(Vendors, First(Filter(Vendors, ID = ThisItem.ID)), Switch(
CurrentUser.Email,"user1@company.com",{User1_Favorite_Column: true},
CurrentUser.Email,"user2@company.com",{User2_Favorite_Column: true}))
CurrentUser in this scenario is OnStart=Set(CurrentUser, User()) so as to be able to use CurrentUser throughout the app to filter Records in a manner compliant with Sharepoint Delegation rules.
The Designer will take the formula without any red squigglies, so I think the syntax is correct. But it's not matching CurrentUser.Email with "user1@company.com". I tried Capitalizing the first letter of the email in the quotes to no avail. So is there another syntax for this that works? Or is there another method to accomplish this that I am missing?
Any help would be appreciated. Thanks in advance!