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 / PowerFX custom command...
Power Apps
Unanswered

PowerFX custom command bar using User() not working

(1) ShareShare
ReportReport
Posted on by 237

I have been creating several custom buttons in a model driven app and they work great.

Now I want to capture the current user who pushed the button but it looks like User().email or User().fullname do not give any result. 

Also hiding the button if the current user is not the record owner doesn't work, because of User()  is empty

How do I determine the current user from the command bar execution? 

 

To 'debug' the issue I patch the record that I'm on to see the value that is received

Mglat_0-1695562922775.png

 

I have the same question (0)
  • Verified answer
    v-xiaochen-msft Profile Picture
    on at

    Hi @Mglat ,

     

    Because User() function is not supported currently.s

    vxiaochenmsft_0-1695606415780.png

    https://learn.microsoft.com/en-us/power-apps/maker/model-driven-apps/commanding-use-powerfx#functions-not-supported

     

    Best Regards,

    Wearsky

     

  • Marcel Lathouwers Profile Picture
    237 on at

    @v-xiaochen-msft That is a great explanation why that doesn't work 😊

     

    Any suggestion how we can build a PowerFX formula that checks on the current user? For instance, check if the current user is the owner of the record

  • EricRegnier Profile Picture
    8,720 Most Valuable Professional on at

    Vote for the idea here 🙂 https://ideas.powerapps.com/d365community/idea/ffb7f338-241a-4302-9b9b-24ae5c40de2b

  • Dominik Stalzer | primeone Profile Picture
    71 on at
    I'm currently struggling with the same problem:
    I can't compare the currently logged-in user with the record owner.
    Has anyone found an alternative solution?
     
    The unsupported User()-function is giving me a headache.
    I voted for the suggested Idea.

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

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 327 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard