Disable submit button in form untill all required fields are filled?

hi any option to disable submit button on a form, until user fill all required fields?

thank you

Screen Shot 2022-11-11 at 2.46.01 PM
You would need to add all fields != '' in that Disable submit field so that in the end they are all accounted for.
This will also depend on whether or not you are using an event handler instead of using form.submit()

1 Like

what you mean by add != '' in all fields?

Try this:
In the submit button's "disabled" or "hidden" options, use some code like this...

{{ input1.invalid || input2.invalid || input3.invalid }}

Replace the "input"s with the field names or identifiers that are required, and make sure your validation rules work.

What "||" is an "OR" operator. Stringing it all together creates a giant boolean where all "input.invalid"s must equal false for the final statement to be "false". If any statement is true, the final statement will return true.

Edit: Putting this code in the submit form container's "disable submit" field would probably be better.

2 Likes

! means NOT
= means EQUALS
'' means "Blank" (thats actually two of ' )

So
!=''
simply means
"isn't blank"

1 Like