Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Apps - Microsoft Dataverse
Answered

If name appears in Dataverse column, change display mode...

(0) ShareShare
ReportReport
Posted on by 802

Hi, 

 

I have a button which I want to have the DisplayMode of Edit if a column on a Dataverse table includes their email address, and Disabled if it doesn't appear in that column. Their email address could appear more than once in this column, but I am only interested if they appear, no matter how many times. 

 

I have tried...

If(First(Filter('DV_Table', 'Manager Email' = User().Email)), Edit, Disabled)

but this errors... any ideas what I'm doing wrong?

 

Thanks

K

  • Verified answer
    Kosenurm Profile Picture
    802 on at
    Re: If name appears in Dataverse column, change display mode...

    Thanks. I got round it another way by using...

     

    If(CountRows(Filter('DV Table', 'Manager Email' = User().Email)) > 0, Edit, Disabled)
  • ChrisPiasecki Profile Picture
    6,389 Most Valuable Professional on at
    Re: If name appears in Dataverse column, change display mode...

    Hi @Kosenurm,

     

    Instead of first + filter, use Lookup. Also, User().Email will give you a delegation warning so I suggest you set that to a variable first then reference the variable in the formula. This also looks like a formula you could reuse elsewhere so you may also want to set the result of this formula to a variable. 

    In your app OnStart:

    Set(EmailVar, User().Email);

    Set(IsManager, If(IsBlank(LookUp('DV_Table', 'Manager Email' = EmailVar)), false, true);

     

    Display Mode formula:

    If(IsManagerVar, Edit, Disabled) 

     

    ---
    Please click Accept as Solution if my post answered your question. This will help others find solutions to similar questions. If you like my post and/or find it helpful, please consider giving it a Thumbs Up.

     

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

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

🌸 Community Spring Festival 2025 Challenge Winners! 🌸

Congratulations to all our community participants!

Warren Belz – Community Spotlight

We are honored to recognize Warren Belz as our May 2025 Community…

Leaderboard > Power Apps - Microsoft Dataverse

#1
mmbr1606 Profile Picture

mmbr1606 22 Super User 2025 Season 1

#2
stampcoin Profile Picture

stampcoin 17

#3
ankit_singhal Profile Picture

ankit_singhal 11 Super User 2025 Season 1

Overall leaderboard

Featured topics