Why is the Add button not grayed out even though I have a required component that has not been completed?

On an Add screen page, I have a Check Box component that is marked as Required. I would like the Add Button to remain grayed out until someone confirms by clicking on it (making it TRUE) - but this does not seem to work because the Add Button becomes valid prior to the user reaching the Check Box.

Not sure if this has anything to do with this issue (I suspect it does) but just prior to the check box I have a bunch of other components, all of which are required, and the last of which is a Date entry field. The Add Button remains grayed out until I reach the Date entry field. If I enter a date that is today or anytime before today, the Add Button becomes valid (before I do anything with the Check Box). This is clearly an error. If I, however, enter a day that is after today the Add Button remains grayed out (which is what I expected).

Is this a bug or am I doing something wrong?

1 Like

Sounds like a bug, but do you have a video or screenshots to demonstrate? Also, can you double check to make sure that the checkbox is marked as required?

I tried in a test app in staging and I couldn’t duplicate the issue.

Thanks @Jeff_Hager.
I actually don’t think it is related to the CheckBox anymore - it is the Date that is the problem (ignore the choice components - the date I am referring to is on the bottom entry titled “C. Reconfirm…”).
Here are 4 screenshots. In each case, there are components above the date that are Required, and the Date itself is also Required. In the first 2 screenshots, you see I have either left the Date blank or had a Date that is after today. In the first 2 the Add Button is grayed out. As soon as I put in a date that is on or before today (last 2) the Add Button becomes live. I hope you are able to duplicate it.

Screen Shot 2020-09-30 at 6.25.24 PM Screen Shot 2020-09-30 at 6.25.59 PM

I can’t seem to duplicate the issue. However I did find a different bug, where you can add a valid date, then remove part of the date to make it an invalid date and it still allows you to add.

Thanks for checking @Jeff_Hager. I had made some edits to my post - I hope you were looking at the latest version of the post as I have spent several days on this problem and am sure it is real.

A related question - the whole reason I was doing this was to make sure that the Add Button be made available only if a Required Check Box (which I did not show in my screen shots - but is at the bottom) was check True. I made the Check Box visible only when the date entered was within a specific range of today (within a year). However, I was unsuccessful because when a user entered a date that was before Today (as explained in my previous post), the Add button became visible - without the user even seeing or touching the Check Box.

How is this possible? Do you have any ideas on how I can get around this?

Only the components which are visible are checked for the “required” condition in a form.
Because your checkbox is not visible when the date is before today, all the conditions for the form to submit have been met and the add button shows up.
You might want to check this thread: Are REQUIRED components only classed as required if visible?

Good to know, @Manan_Mehta.
For the record, even when I make the component visible, the Add Button was made valid if a Date is entered that is on or before today. This is indeed very frustrating.
It does not look like @Jeff_Hager was able to duplicate the Date issue - did you (@Manan_Mehta) come across it?

OK, this makes sense now. I didn’t realize you were conditionally showing the checkbox base on the date. Yes, it’s true and expected behavior that components marked as required and that are made visible will be required to be filled out. Once you hide the component through visibility, then it is no longer required. This makes sense in certain situations where someone may not want to display all components, but if they do, then the app builder may want the user to be required to fill in the additional information. Since you were hiding the checkbox when the date was on or before today, then it was no longer required to fill the checkbox. Also, since the date is then filled in, that meets the requirement of just having a date in the component and activates the Add button. Currently there aren’t any settings for specifying a valid date range, like there is for numeric or text entry components.

From what I understand, it’s working as intended.

@Jeff_Hager unfortunately that is not the case. Sorry if I confused things.

As of now (at least for me), even with the Check Box visible and unchecked, if there is a Date component entered above it that is on or before today, the Add Button becomes valid. Correct me if I am wrong but this should not happen until the Check Box has been checked.

I hope you (and others) can duplicate and verify.

If you can duplicate you app or make a simplified copy that we can copy, it might be easier to see if it’s something with your particular setup.