0
How to convert String date into Date obj
DateFormat df = new SimpleDateFormat("dd/MM/yyyy");
try
{
Date today = df.parse("10/12/2009"); //converts String object into Date Object
System.out.println("Today = " + df.format(today)); //formats the Date object accourding to the format mentioned above
} catch (ParseException e)
{
e.printStackTrace();
}
try
{
Date today = df.parse("10/12/2009"); //converts String object into Date Object
System.out.println("Today = " + df.format(today)); //formats the Date object accourding to the format mentioned above
} catch (ParseException e)
{
e.printStackTrace();
}