I am working on a java project using SQL and I need to display the current date on a JDateChooser
.
Before my client change it with his need I used this in the constuctor
java.sql.Date date = new java.sql.Date(new java.util.Date().getTime());
jdatechooser.setDate(date);
I've also tried
java.util.Date mydate = new java.util.Date();
jdatechooser.setDate(date);
But neither of them work. Any help, please?