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 / How to properly search...
Power Apps
Unanswered

How to properly search in "Created by"

(0) ShareShare
ReportReport
Posted on by 48

HI,

 

can someone help me figure out how to properly search in "created by" (data source = SharePoint list) column of data table? 

 

Currently I'm using "AddColumns" and it works great, I can search according to user name .... but just because of that I have problems with my next screens (e.g. Detail screen - showing "Data source" error).

 

Simply, datatable.selected doesn't show any records details. Everything's back to normal when I remove "AddColumns".

I assume it's because I added new column with "Addcolumns" function which doesn't exist in my origin data source.

 

My Home Screen data table "Items" formula:

 

SortByColumns(
Search(
AddColumns(MySharePointlist, "CreatedByUser", 'Created By'.DisplayName),
SearchInput.Text,
"CreatedByUser",
"Title",

...other text columns to search...
), "Created", Descending)

 

 

Data source error on my detail screen:

Error.JPG

 

So...

1, is there any other way how to search in "Created by" column, without using AddColumns

or

2, how to adapt my next screens (e.g. detail screen) data source while using AddColumns in my home screen? 

 

 

Categories:
I have the same question (0)
  • mdevaney Profile Picture
    29,989 Moderator on at

    @Lubeno78 
    You can use a ComboBox control with this code in the Items property to look for the user.

     

    Choices(your_datasource_name.'Created by')

     

     

    Then use this code in the Items property of your data table

     

    Filter(your_datasource_name, 'Created by' = ComboBox1.Selected)

     

     

    Watch this video if you require a full set of instructions:

    https://www.youtube.com/watch?v=tPxE_-DcWkg

     

    ---
    Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

  • CU29100747-0 Profile Picture
    48 on at

    @mdevaney  thank you for reply.

     

    Combo box with "Choices(MySharePpointList.'Created By') shows only some strange ID's, see below. 

    .DisplayName is not possible to use.

    How to show user's name?

     

    users.JPG

  • mdevaney Profile Picture
    29,989 Moderator on at

    @Lubeno78 

    You'll want to change both the DisplayFields and SearchFields property of the Combobox to this code

    ["DisplayName"]

     

    ---
    Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

  • CU29100747-0 Profile Picture
    48 on at

    @mdevaney  sorry, but that doesn't work. 

    ...["DisplayName"]

    showing me "member of..." text, I don't know why.

    I tried all other options (JobTitle, Email, Dept...), same strange results. Do you know why? 

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 739 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 343 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard