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

Announcements

News and Announcements icon
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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the April Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Vish WR Profile Picture

Vish WR 1,074

#2
Valantis Profile Picture

Valantis 639

#3
11manish Profile Picture

11manish 606

Last 30 days Overall leaderboard