cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

Question about Button "OnDisplay"

Hello.

I am fairly new to PowerApps. I have this form where I want the Next button to be unclickable until 4 dropdowns have values (when the user selects one of the choices). The first drop down is in reference to "DataCardValue9". This is the code I used on the DisplayMode of the Next button and it's working.

 

If(IsBlank(DataCardValue9.Selected), DisplayMode.Disabled, DisplayMode.Edit)
 

There are another 3 dropdowns below that and one optional text box which I am not concerned about. The drop downs are all mandatory. They are named DataCardValue10, DataCardValue11, and DataCardValue12 respectively (underneath 9 which is already working)

 

How would I amend my line of code to include those having to not be blank as well? I've been racking my brains for a while. When DataCardValue9 is empty the Next button can't be clicked which is great but I need those others as well. I think there should be an AND statement in there but I just can't seem to get it to work. I tried this but didn't work.

 

If(IsBlank(DataCardValue9.Selected) And IsBlank(DataCardValue10.Selected) And IsBlank(DataCardValue11.Selected) And IsBlank(DataCardValue12.Selected), DisplayMode.Disabled, DisplayMode.Edit)

Any help is much appreciated! Thanks.

1 ACCEPTED SOLUTION

Accepted Solutions
KrishnaV
Community Champion
Community Champion

Hi @Anonymous ,

 

use Or instead of And the same formula works seamlessly for you!

 

Regards,

Krishna

 



I hope this resolved your issue if you see any challenge/need further help please let me know I am always happy to do it for my community.

Regards,
KrishnaV
Business Applications MVP, Microsoft Certified Trainer
Twitter | Linkedin | YouTube | GitHub
If this post helps you give a THUMS-UP and if it solved your issue consider Accept it as the solution to help the other members / new members of the community.

View solution in original post

2 REPLIES 2
KrishnaV
Community Champion
Community Champion

Hi @Anonymous ,

 

use Or instead of And the same formula works seamlessly for you!

 

Regards,

Krishna

 



I hope this resolved your issue if you see any challenge/need further help please let me know I am always happy to do it for my community.

Regards,
KrishnaV
Business Applications MVP, Microsoft Certified Trainer
Twitter | Linkedin | YouTube | GitHub
If this post helps you give a THUMS-UP and if it solved your issue consider Accept it as the solution to help the other members / new members of the community.

Anonymous
Not applicable

Thank you!! All these hours trying to troubleshoot and it was me being silly using AND instead of Or.

 

Confirmed that this works

 

If(IsBlank(DataCardValue9.Selected) Or IsBlank(DataCardValue10.Selected) Or IsBlank(DataCardValue11.Selected) Or IsBlank(DataCardValue12.Selected), DisplayMode.Disabled, DisplayMode.Edit)

 

 

Thank you so much!!

Helpful resources

Announcements
Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Community Call Conversations

Introducing the Community Calls Conversations

A great place where you can stay up to date with community calls and interact with the speakers.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (4,615)