Hi 🙂
I have a form that has a datepicker and a button for sending input and I would like my users to be able to choose only the current or future dates and not the past ones.
What I am doing and inform (visuall) the user that it is an invalid entry. For example, in the app shown below, when the date is selected, the border of the selector is changed and an error message is displayed:
DatePicker1.BorderColor: If(DatePicker1.SelectedDate<DateAdd(Today();-7;Days) || DatePicker1.SelectedDate>Today();Red;RGBA(67; 152; 209; 1))
Label1.Text: If(DatePicker1.SelectedDate<DateAdd(Today();-7;Days);"Maximum 2 days before today";DatePicker1.SelectedDate>Today();"Not after today";"")
Label1.Color: Red
Label1.Visible: DatePicker1.SelectedDate<DateAdd(Today();-7;Days) || DatePicker1.SelectedDate>Today()
Button.DisplayMode:If(DatePicker1.SelectedDate<DateAdd(Today();-7;Days) || DatePicker1.SelectedDate>Today();Disabled;Edit)
All this works perfectly but it works alincontario.io I have to give the possibility to select 7 future not passed.
Thank you all for your help

Report
All responses (
Answers (