How to make sure an user inputs only double values in a given TextField?
I found a solution for integers bu I can\'t manage to use it for doubles.
You could make use of Double.parseDouble Double Javadoc. This will do the parsing for you, rather than writing your own double validation. You can then check for a number format exception or null pointer exception.
try
{
Double.parseDouble(newValue);
// Valid double
}
catch (NullPointerException | NumberFormatException ex)
{
// Not valid double
}