Question: Field Input Restrictions

Does anyone know how to accomplish the following:

  • Prevent users from putting letters in number fields
  • Prevent negative numbers
  • When selecting date, cannot select previous dates only future dates.
  • Is there a time input on iphone? The time input still asks for date?

Any insight?

1 Like

The type of entry component you choose will determine which keyboard shows on phone devices (IOS is a little odd with number and phone pads) and at least with the number entry, you should not be able to type non numeric characters.

The new Min and Max values on Numeric Entry components should prevent negative numbers.

I’m not aware of any way to restrict Date entry to only future dates, but depending on you situation, you can show or hide different components or buttons based on the date entered. You could also build a list of dates in your sheet and display them as a choice component.

There is no Time Only entry. Only Date and Date/Time, although you can set it to display only time after it’s entered.

Thank you for the info @Jeff_Hager! The use case for the date limitations would be to prevent users from booking past dates. I would imagine I am not the only person with this request.

Do you know if the date restriction is on the roadmap for the Glide Team?

3 Likes

No idea what Glide has planned for the future.

Totally support this new feature request, something like this

image

2 Likes

To prevent past dates, try to gather the requested date before the form submission and use that selection to show or hide the form button — making it only visible if the selected date is on or after today. You’d bring the date value over to your form submission by adding a column value in the form screen.

You could also do this by using a pre-defined list of dates in your form, and filter the choice list to only include values on or after today. This may not be feasible though unless you’re only looking to allow certain dates to be booked.

See this post for more info: Super Simple Sign-up App with limited time slots

1 Like