[program-java] date validation



Do you have a date validation routine?

I have one, it's ugly enough. It checks the value of the month, then the
value of the day, compares it with the array of valid values.

I need more professional one, that uses Java classes.


I was also looking for a numeric field validation, but just found one.

And want to share it with our people.

It's neat, isn't it?

I'm looking for a date validation routine in the similar style.


Thank you and the code follows.



  int number=0;   

      while (number == 0) {   

    String input=JOptionPane.showInputDialog("\n\tEnter numeric value.");   



    }catch(NumberFormatException nfe)   


Number = 0;   



Other related posts: