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 / Disable Function on bu...
Power Apps
Answered

Disable Function on button with multiple selections in the form Power Apps

(0) ShareShare
ReportReport
Posted on by 433

Hello Power Users,

 

I'm building a power apps with couple of combo boxes that appear based on a selection from drop down. The drop down values are approve and Reject. I have items on Combobox1 items in format [" ","One","Two"]. I have items on Combobox2 items in format [" ","Three","Four"]. I want the submit button to be enabled only if the Combobox1 has selection values other than " " when approve is selected and same for Combobox2 has any selection values other than " ", when reject if selected . 

 

I did the formulae with some || conditions like if

 

If((Combobox1.visible && Combobox1.Selected.Value = " ") || (Combobox2.visible && Combobox2.Selected.Value = " "),DisplayMode.Disabled,DisplayMode.Edit)

I had the if condition written correct not sure if I'm missing anything with || and && conditions. 

 

Can anyone please help or suggest.

 

Thanks in advance!

Categories:
I have the same question (0)
  • NZ0090 Profile Picture
    317 on at

    @KrishR It could be because nothing was selected when you first run the app. Try adding [" "] in the DefaultSelectedItems property of your combobox.

  • Verified answer
    v-qiaqi@microsoft.com Profile Picture
    Microsoft Employee on at

    Hi @KrishR,

    Do you want to enable the submit button either when:

    1). Combobox1 has selection values other than " " when approve is selected

    OR

    2). Combobox2 has selection values other than " " when reject if selected

     

    If so, modify your formula as below:

     

    If((Combobox1.Visible&&Combobox1.Selected.Value <>" "&&Dropdown.Selected.Value="Approve") || (Combobox2.Visible&&Dropdown.Selected.Value="Reject" && Combobox2.Selected.Value <> " "),DisplayMode.Edit,DisplayMode.Disabled)

     

    Not sure why you refer to Combobox1.visible.

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

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 355 Most Valuable Professional

#2
11manish Profile Picture

11manish 209 Super User 2026 Season 2

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 150 Super User 2026 Season 2

Last 30 days Overall leaderboard