web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Filter gallery based o...
Power Apps
Unanswered

Filter gallery based on displayName from a SharePoint person column

(0) ShareShare
ReportReport
Posted on by 2,563

Hi

 

In my SharePoint list i have a person column named "Assigned To"

What i would like to do is filter a gallery to only show items that I'm assigned to.

 

I created a variable.
Set(varDisplayName, User().FullName);

Now i did not use User().Email because email will display wrong due to some users email is not all lower characters.

My question is will User().FullName match the data from the "Assigned To" column: 'Assigned To'.DisplayName or will it be like it is with .Email?

 

How else can i solve this?

I did a solution for the Created by where i write the created by email to another column with all lower cases but i cannot do this with the Assig

Categories:
I have the same question (0)
  • WarrenBelz Profile Picture
    153,024 Most Valuable Professional on at

    Hi @JimmyWork ,

    As long as Assigned To containers the exact spelling of User().FullName, a filter will work.

    You can also use Lower() on both to get rid of any case sensitive issues.

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

  • JimmyW Profile Picture
    2,563 on at

    @WarrenBelz I can't use Lower because i cannot delegate using Lower and im wondering how User().Fullname compares to the data from the person field using displayName, i do know that .Email will not be the same from a person column and the User().Email so im wondering if maybe displayName will always match? What is displayName actually pulling from compared to the User().Fullname?

  • WarrenBelz Profile Picture
    153,024 Most Valuable Professional on at

    Hi @JimmyWork ,

    Yes - Lower is not delegable unless you can collect the data and and then use Lower on varDisplayName.

    The comparison to the Person field depends on where you are getting this from.

  • JimmyW Profile Picture
    2,563 on at

    @WarrenBelz Thank you for answering

     

    If i would do Lower on varDisplayName then it will not work as i cannot do Lower on the AssignedTo.DisplayName

    Im getting the AsiignedTo.Displayname from a SharePoint column

    Powerapps is then using the User().Fullname and i do not know where the 2 different locations pull the data from.

     

    Im not sure if i can create a variable that is Lower(AssignedTo.Email) but im pretty sure i can't

  • Verified answer
    v-yutliu-msft Profile Picture
    on at

    Hi @JimmyWork ,

    Do you want to compare User().FullName with a person column value in sharepoint list?

    Does your person field allow multiple person choice?

    You just need to use formula like this:

    Filter(table,User().FullName='Assigned To'.DisplayName)

    I know you are worried about the letter case of  User().FullName and DisplayName in person field.

    Don't worry, these two's value are the same.

    Although these two value comes from different places, one from powerapps, one from sharepoint.

    But actually their data source is the same.

    These two names  all come from your Office365 profile.

     

    If you are still worried about this, you could check the DisplayName of 'Assigned To' in your app directly.

    For example:

    Insert a combo box, set the combo box's Items:

    Choices(listname.'Assigned To')

    Set the combo box's primary text to DisplayName. 

    Then you could search yourself in the combo box, the combo box will display your DisplayName.

    Insert another label, set its Text to :User().FullName .

    Then compare the value displaying in the combo box and the label. I believe they are the same.

     

     

     

    Best regards,

     

  • WarrenBelz Profile Picture
    153,024 Most Valuable Professional on at

    Hi @JimmyWork ,

    Timezone issues have prevented me responding until now.

    I will leave you with @v-yutliu-msft here unless you want further input from me (tag me if so).

  • Lee123 Profile Picture
    27 on at

    Hi Phoebe

    I have the same need, and I can't see why this code doesn't work - MinisterialAuthor is a vanilla person column from a modern sharepoint list, Ministerials.

    Filter([@Ministerials], MinisterialAuthor.DisplayName = User().FullName )
     
     
    Error is "Invalid Argument type", and the formula is in the items property of a gallery.
     

     

     

  • PowerAppNoob Profile Picture
    47 on at

    Hi @v-yutliu-msft! I have the same requirement but mine would be based on email address. I am creating an app where I am using the gallery items to populate the form based on an SP list. These gallery items are based on the country keyed-in in the text input and can be processed by 1 or more persons depending on the email address(es) indicated in a column in the SP list called "System Owner Email Add". However, the current formula that I am using can only accept 1 email address. If the cell in the in the column "System Owner Email Add" contains multiple emails address, the gallery items will only be visible to the first email address in the cell.

     

    My goal is for the galley items to be visible to all the users indicated in the "System Owner Email Add" column and any of them will be able to process the task.

     

    Below is the simplified SP List.

     
    Server NameCountrySystem Owner Email AddAction Taken
    Server ACountry Aabc@abc.com
    def@abc.com
    ghi@abc.com
    This will be based on whichever action is selected in the app by the System Owner.
    Server BCountry Bjkl@abc.com
    mno@abc.com
    This will be based on whichever action is selected in the app by the System Owner.

     

    Appreciate your advice.

  • ricklazarus Profile Picture
    20 on at

    You rock! It worked for me! I'm working on a Vacations requests app and wnated to show just the data for de current user.

    Thanks!!

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 793 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 333 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard