Important Notice - Forums is archived
To simplify things and help our users to be more productive, we have archived the current forum and focus our efforts on helping developers on Stack Overflow. You can post new questions on Stack Overflow or join our Discord channel.

TUTORIALVaadin lets you build secure, UX-first PWAs entirely in Java.
Vaadin lets you build secure, UX-first PWAs entirely in Java.
Free ebook & tutorial.
Calling javascript synchronously by Enver Haase, 2 weeks ago
How to override date validation client side
I'm new in with vaadin framework I would like to extend the DateField and validate the date enterred by the user in "client side" server is already done
Example : if user write "today" is become "18.05.2015"
Thanks for all your help.
Last updated on
In server side it is quite easy to do this kinds of parsing manipulations.
Why you want to do it in browser?
DateField df = new DateField() {
@Override
protected Date handleUnparsableDateString(final String dateString)
throws Converter.ConversionException {
if("today".equals(dateString)){
return new Date();
}
throw new Converter.ConversionException("UNABLE PARSE DATE");
}
};
Last updated on
+1
Thank you Vesa for you help, because in my point of view when you put today in a date and is not evaluation right away is not good.
Server side is a double validation in case...
Last updated on
You cannot reply to this thread.