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 / Set combo box default ...
Power Apps
Answered

Set combo box default item to the current user

(0) ShareShare
ReportReport
Posted on by

Hi all,

 

I have another question. On the home screen of one of my apps the users search for and select themselves so they can record data about what work they're doing throughout the day.

 

The combo box is a standalone input field, so not part of a form. The items property is: Filter(Office365Users.SearchUser({searchTerm: Self.SearchText}), Department = "Corporate Resources, IBC").

 

I cannot figure out what piece of code to put in the DefaultSelectedItems property of the combo box.

 

I think it needs to be something like this(?): Filter(Office365Users.SearchUser({searchTerm: Self.SearchText}), Mail = User().Email).

 

The screen looks like this: 

freddiejoseph1_0-1615201967462.png

 

I have seen lots of posts about doing this using sharepoint as a datasource, but not the O365 Users connector.

 

Thanks,

 

Freddie

 

Categories:
I have the same question (0)
  • JR-BejeweledOne Profile Picture
    5,836 Moderator on at

    You said:

    I think it needs to be something like this(?): Filter(Office365Users.SearchUser({searchTerm: Self.SearchText}), Mail = User().Email).

     

    Have you tried this?

  • timl Profile Picture
    36,387 Super User 2025 Season 2 on at

    Hi @Anonymous 

    You might find that just setting the DefaultSelectedItems property to this will work.

    [User().Email]

     

  • Verified answer
    Community Power Platform Member Profile Picture
    on at

    You're very close! This will work to default select the current user:

     

    First(Office365Users.SearchUserV2({searchTerm:User().Email}).value)
  • Community Power Platform Member Profile Picture
    on at

    Thanks. This works perfectly!

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

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 319 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard