cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Frequent Visitor

search for user by name, mail AND Phone number?

I can search for users by name or email. But i would also like to enable search by phone number.

 

Cant get it to work in the same field, and not even in a separate numberical search field. It shows the phone number when i search for a user by name or email, the phone number is here, First(Office365Users.UserProfile(First(EmployeeProfile).Mail).BusinessPhones).Value)

 

Can anyone give me a hint on how to get it working?

4 REPLIES 4
Highlighted
Dual Super User III
Dual Super User III

Re: search for user by name, mail AND Phone number?

Hey @Oliver_Hagvall 

 

Can you share more details about the scenario you are trying to build? Based on the information shared by you, you have a second screen, on which the data is filtered, right?
 
Please share more details about the controls and we might be able to help you better in building the formulas.
 
You can use AddColumns to add a column for user's phone number and then you can search it.
 
Search(AddColumns(EmpDirectoryDataSource, "PhoneCol", First(Office365Users.UserProfile(First(EmployeeProfile).Mail).BusinessPhones).Value),TextInput1.Text,"PhoneCol")
 
Hope this Helps!

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!
Highlighted
Solution Supplier
Solution Supplier

Re: search for user by name, mail AND Phone number?

Please first verify that the formula is correct. there is a syntax error in your formula. it could be a typo:

 

there is an extra parenthesis

First(Office365Users.UserProfile(First(EmployeeProfile).Mail).BusinessPhones).Value)

Highlighted
Frequent Visitor

Re: search for user by name, mail AND Phone number?

Thank you for your help, but it does not seem to work. I can get it to show the phone number when i´ve searched for a user but i cant get it to search for a user by phone number. 

Highlighted
Dual Super User III
Dual Super User III

Re: search for user by name, mail AND Phone number?

Hey @Oliver_Hagvall 

 

Can you please share the error details that you are getting while using the below expression?

Search(AddColumns(EmpDirectoryDataSource, "PhoneCol", First(Office365Users.UserProfile(First(EmployeeProfile).Mail).BusinessPhones).Value),TextInput1.Text,"PhoneCol")

 

Hope this Helps!

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

Helpful resources

Announcements
secondImage

New Return to Workplace

Reopen responsibly, monitor intelligently, and protect continuously with solutions for a safer work environment.

Experience what’s next for Power Apps

Join us for an in-depth look at the new Power Apps features and capabilities at the free Microsoft Business Applications Launch Event.

Check this Out

Helpful information

Featuring samples like Return to the Workplace and Emergency Response Applications

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Solution Authors
Top Kudoed Authors
Users online (5,965)