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 / If statement Not equal to
Power Apps
Answered

If statement Not equal to

(0) ShareShare
ReportReport
Posted on by

I am trying to write an If statement like "If(IsBlank(field)" but I need it to be "If not = to "Select...""(field)"  How can you write something like that?  I want the action to run as long as the field value is not "Select..."

Categories:
I have the same question (0)
  • seadude Profile Picture
    1,855 on at

    Hm.

     

    Its tough for me to understand exactly what you are looking for here. But I'll try:

    It sounds like you have a Textbox with "Select x" in it and you want to say,

    If textbox.text has the string "Select x" in it, do something. 

    If thats the case try:

    If(
     IsMatch(textBox.Text, "Select x"),
     doSomethingCool,
     beLame
    )

    I tested this. It works. Here are the docs. When in doubt, consult Mr. Dang (a true treasure to the PowerApps community)!

  • PowerAid Profile Picture
    on at
    IsMatch(textBox.Text, "Select x"), doSomethingCool, beLame )

    I tested this. It works. Here are the docs. When in doubt, consult Mr. Dang (a true treasure to the PowerApps community)!


    Ok.  I am actually wanting a Patch to NOT run if the value of the dropdown = "Select..."  .  Is there an opposite of IsMatch?

     

    This is part of a repeating table that I have designed.  The Patch will write values to my SharePoint list ('Revenue Pre-Defined Categories').  One of the fields in my repeating table is a dropdown and I dont want it to write to SharePoint if that dropbown has not been set to something other than Select.

     

    ForAll(RevenuePreDefinedCollection, Patch('Revenue Pre-Defined Categories', Defaults('Revenue Pre-Defined Categories'), {Title: CategoryCC, AmountEach: AmountEachCC, Quantity: QuantityCC, Subtotal: SubtotalCC, MasterID: Form1.LastSubmit.ID}))


    @seadude wrote:

    Hm.

     

    Its tough for me to understand exactly what you are looking for here. But I'll try:

    It sounds like you have a Textbox with "Select x" in it and you want to say,

    If textbox.text has the string "Select x" in it, do something. 

    If thats the case try:

    If(
                          
  • Verified answer
    seadude Profile Picture
    1,855 on at
    Aha. You can usually put a “!” in front of your statement to make it a “NOT”.

    Another option may be:
    - Set the Submit Button DisplayMode Property to:

    If(
    Dropdown.Selected.Value = “Select”,
    DisplayMode.Disabled,
    DisplayMode.Edit
    )

    This is a type of manual error handling you can use for different things.
    Coupled with some And() / Or() functions make it quite powerful.
  • NickSoan Profile Picture
    16 on at

    The Microsoft DAX language for the PowerPlatform tools doen't have the operator !=, but it does have <>

    If( DropDown.Selected.Value <> "View", 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 536

#2
WarrenBelz Profile Picture

WarrenBelz 426 Most Valuable Professional

#3
Haque Profile Picture

Haque 305

Last 30 days Overall leaderboard