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 / Using two conditionals...
Power Apps
Answered

Using two conditionals at once

(0) ShareShare
ReportReport
Posted on by 878

So I have a text input that should be required when two conditions met:

1- That the current user's email is one of the emails in a previously created collection of emails called colteamPT

2- That an input of yes/no was set to false

 

The first part i made it with this code:

 

If(
 CountIf(colTeamPT; Trim(Lower(Mail)) = Lower(Trim(User().Email))) > 0;
 false;
 true
)

 

What I can figure out for the false Datacard part is this?

 

If(
 DataCardValue2.Value = false && CountIf(colTeamPT; Trim(Lower(Mail)) = Lower(Trim(User().Email))) > 0;
 false;
 true
)

 

But nope, even if I mark as TRUE the value, it still ends up being a required text 😞

 

Categories:
  • Verified answer
    Rajkumar_M Profile Picture
    3,747 Moderator on at

    Hi @WorkingRicardo 

     

    Try this formula,

     

    If(
     DataCardValue2.Value = false && 
    CountIf(colTeamPT; Trim(Lower(Mail)) = Lower(Trim(User().Email))) > 0; true; false )

     

    Thanks!

     

    If my response has been helpful in resolving your issue, I kindly request that you consider clicking "Accept as solution" and "giving it a thumbs up" as a token of appreciation.

     

     

  • WorkingRicardo Profile Picture
    878 on at

    @Rajkumar_404 hey ty for your reply!
    Oh, inverting the true and false? Did that but now in any case, the text box never shows up as required 😞 Not if DataCardValue is true or false. What else could be tried?

  • WorkingRicardo Profile Picture
    878 on at

    wait sorry! I tweaked other things in the app and this was the correct code you're right 🙂

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 405 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 368

#3
WarrenBelz Profile Picture

WarrenBelz 244 Most Valuable Professional

Last 30 days Overall leaderboard