/** * Create a new date from day, month and year (French version). * The month is the real month of the year and not the one which is stored * in Calendar object. Time is set to 00:00:00.000 * * @param dd value of the day 1-31 * @param mm value of the month 1-12 * @param yy value of the year 0-9999 * @return a new date */ public static Date createDate(int dd, int mm, int yy) { Calendar calendar = Calendar.getInstance(); calendar.set(Calendar.YEAR, yy); calendar.set(Calendar.MONTH, mm - 1); calendar.set(Calendar.DAY_OF_MONTH, dd); return setMinTimeOfDay(calendar.getTime()); }