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 connect to spec...
Power Apps
Unanswered

How to connect to specific fields in AD

(0) ShareShare
ReportReport
Posted on by 6

Hi.  I think my issue is fairly easy  (for you guys 🙂   )      So the company I work for uses employee IDs for many of our logons,  ID providers, etc.    I get tired of having to log into AD, find the user, and then navigate to appropriate tab to get the user ID .   I'm trying to build the most basic of apps that will allow me to type in the name, see the ID number.  That's it!  

 

I've added a connector of MSOffice365Users as that appears to be the closest thing I can come to AD (not azure AD, but the original MS AD).  The field I need to get the data from is placed in the user properties , under the ACCOUNT tab, in the field  of 

 

"User Logon name (pre-Windows 2000):

__XXX\____________________________     ______(this is the field I need right here)________________________________  

 

Thank you for any assistance. 

Categories:
I have the same question (0)
  • M_Ali_SZ365 Profile Picture
    1,110 on at

    Hi @scromer ,

    To create a simple app for fetching an employee ID from Active Directory, follow these steps:

    Use the Office365Users connector.
    Create a text input to enter the user's name.
    Add a button to search for the user ID based on the name.
    Place a label to display the ID.
    Set the button’s OnSelect function to:

    Set(varUser, Office365Users.SearchUser({searchTerm: TextInput1.Text}))

    Set the label’s Text function to:

    varUser.mailNickname

    This assumes mailNickname corresponds to the "pre-Windows 2000" login name. If this isn't the case, or if you need a different field from AD, you might need a custom connector or additional steps based on your AD setup. Ensure you have the permissions to access the information.

    Please accept this solution if it resolves the issue. ✅
    Best regards,
    Muhammad Ali

     

     

  • scromer Profile Picture
    6 on at

    That makes sense!!!   I will try now!!!

  • scromer Profile Picture
    6 on at

    It didn't work.   The error that keeps getting returned is " mailNickname not recognized."  I then tried to use the "userLogonName"  field, and that was also not recognized.  Any suggestions on how to map to that specific field?

  • scromer Profile Picture
    6 on at

    I got it!  Thank you for setting me on the correct path!!!!

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