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 / Have an error with the...
Power Apps
Answered

Have an error with the Or function

(0) ShareShare
ReportReport
Posted on by 31

Hello 

 

I've been working on disabling a button when certain parameters are not meet in a form. Now this feature was working very well and then suddenly it stopped working and I am unsure why this is. The code I am using is - 

 

If (DataCardValue8.Text = "A" || "N" || "X" || "" , DisplayMode.Disabled, Edit)

 

This can also be seen in the photos below. 

 

As you can see I want it to disbale the submit button when the Text is A,N, X or blank. But it is only working when it is A and I've moved around the letters and it is only working for the first letter. Does anyone know why this is and how I can fix it? 

 

Capture1.PNGCapture2.PNG

Categories:
I have the same question (0)
  • Verified answer
    Pstork1 Profile Picture
    69,270 Most Valuable Professional on at

    I don't think you can use OR using the syntax you are using.  The whole equation needs to be added to the OR.  Something like this.

    If (DataCardValue8.Text = "A" || DataCardValue8.Text = "N" || DataCardValue8.Text = "X" || DataCardValue8.Text = "" , DisplayMode.Disabled, DisplayMode.Edit)

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 March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 514

#2
WarrenBelz Profile Picture

WarrenBelz 419 Most Valuable Professional

#3
Valantis Profile Picture

Valantis 295

Last 30 days Overall leaderboard