cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Post Patron
Post Patron

How to make a dropdown required to be filed out before submitting a form

I am trying to make these fields attached below all required before submitting a form (The Submit button will not be clickable). It works for text inputs but with the dropdowns I'm doing something wrong. How can I make a choice within the dropdown blank to work with this code, other than including "" in the items field because that didn't work for me. 

 

The Displaymode for my Submit button:

If( (IsBlank(StandardEndorserName1E.Text)) || (IsBlank(DesignNumberE.Text))|| (IsBlank(DepartmentE.AccessibleLabel))|| (IsBlank(ModuleE.AccessibleLabel)), DisplayMode.Disabled, DisplayMode.Edit )

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Super User III
Super User III

Re: How to make a dropdown required to be filed out before submitting a form

@pnass001 
See my code below.  You'll want to refer to the Selected property with the your column name.  Many times this is just Dropdown.Selected.Value.  

 

If(
    IsBlank(StandardEndorserName1E.Text
    || IsBlank(DesignNumberE.Text)
    || IsBlank(DepartmentE.AccessibleLabel)
    || IsBlank(ModuleE.AccessibleLabel)
    || IsBlank(Dropdown.Selected.Column_Name),
    DisplayMode.Disabled,
    DisplayMode.Edit
)

 

---
Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

View solution in original post

5 REPLIES 5
Highlighted
Super User III
Super User III

Re: How to make a dropdown required to be filed out before submitting a form

@pnass001 
See my code below.  You'll want to refer to the Selected property with the your column name.  Many times this is just Dropdown.Selected.Value.  

 

If(
    IsBlank(StandardEndorserName1E.Text
    || IsBlank(DesignNumberE.Text)
    || IsBlank(DepartmentE.AccessibleLabel)
    || IsBlank(ModuleE.AccessibleLabel)
    || IsBlank(Dropdown.Selected.Column_Name),
    DisplayMode.Disabled,
    DisplayMode.Edit
)

 

---
Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

View solution in original post

Highlighted
Post Patron
Post Patron

Re: How to make a dropdown required to be filed out before submitting a form

@mdevaney  Ok done, but what happens if they don't fill in the text inputs and drop downs? I want the Submit Button to not be able to be clicked on. What can I do to rework the code I posted above to make the button's displaymode enabled only if all fields have been filled out

Highlighted
Super User III
Super User III

Re: How to make a dropdown required to be filed out before submitting a form

@pnass001 
OK.  I thought you had already worked out the rest.  I'm kind of confused about your references to the accessible label.  Here's the generic code you could write for the 4 required fields

 

If(
    IsBlank(TextInput_StdEndorsersName.Text)
    || IsBlank(DepartmentE.Selected.Value)
    || IsBlank(ModuleE.Selected.Value)
    || IsBlank(DesignNumberE.Text),
    DisplayMode.Disabled,
    DisplayMode.Edit
)

 

---
Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

Highlighted
Post Patron
Post Patron

Re: How to make a dropdown required to be filed out before submitting a form

@mdevaney It works! Thanks. Forget my previous reply. Was in regards to another comment.

Highlighted
Super User III
Super User III

Re: How to make a dropdown required to be filed out before submitting a form

@pnass001 

I’m glad you let me know, I was confused lol!

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

Watch Now

Experience what’s next for Power Apps

See the latest Power Apps innovations, updates, and demos from the Microsoft Business Applications Launch Event.

Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Solution Authors
Top Kudoed Authors
Users online (7,845)