Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
Anonymous
Not applicable

Using current Active Directory user as a parameter

Hi, I am trying to use the name of the current Active Directory logged user as a parameter in Power Query, because I need to include it as a filter for another query, but I can't find a way. I have searched for a possible solution in this forum, but I haven't found anything related. Is there any way of doing that? Thanks in advance!

1 ACCEPTED SOLUTION
Jimmy801
Community Champion
Community Champion

Hello @Anonymous 

 

i was trying to analyse the information that is queried with the function ActiveDirectory.Domains and I didn't find any information of the current log on. Als the credential needed to access ActiveDirectory are anonymous and you can not query them. I think there is no way to do that in power query. However if you are using Excel you could write a Macro and get the Application.UserName or access Windows somehow to get the user. I don't know if this would be a solution for you. 

 

If this post helps or solves your problem, please mark it as solution (to help other users find useful content and to acknowledge the work of users that helped you)
Kudoes are nice too

Have fun

Jimmy

View solution in original post

2 REPLIES 2
v-kelly-msft
Community Support
Community Support

Hi  @Anonymous ,

 

Try the graph API: https://msdn.microsoft.com/en-us/library/azure/ad/graph/api/api-catalog

 

Best Regards,
Kelly

Did I answer your question? Mark my post as a solution!

Jimmy801
Community Champion
Community Champion

Hello @Anonymous 

 

i was trying to analyse the information that is queried with the function ActiveDirectory.Domains and I didn't find any information of the current log on. Als the credential needed to access ActiveDirectory are anonymous and you can not query them. I think there is no way to do that in power query. However if you are using Excel you could write a Macro and get the Application.UserName or access Windows somehow to get the user. I don't know if this would be a solution for you. 

 

If this post helps or solves your problem, please mark it as solution (to help other users find useful content and to acknowledge the work of users that helped you)
Kudoes are nice too

Have fun

Jimmy

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

Check out the June 2025 Power BI update to learn about new features.

June 2025 community update carousel

Fabric Community Update - June 2025

Find out what's new and trending in the Fabric community.