How to get time and date from the date filed

Hello to all,
I am using a DateField component in which i need to get both the selected date and time. On calling getValue method i only get the date only.
Can you please help me. Below is a sample code…

    startDate=new DateField("Starting at",new Date());
    startDate.setDateFormat("yyyy-MM-dd HH:mm");

startDate.setResolution(DateField.RESOLUTION_MIN);

java.util.Date d=(java.util.Date) startDate.getValue();

You know, that the java.util.Date class ist actually a timestamp (milliseconds since Jan. 1st, 1970)?
If you want to extract time and date you have to use a Calendar. Just create one with the Date object:

Calendar calendar=Calendar.getInstance();
calendar.setTime(date);

Then you can extract minute, hour, day, month and year separately:

int minute=calendar.get(Calendar.MINUTE); // 0 - 59
int hour=calendar.get(Calendar.HOUR_OF_DAY); // 0-23
int day=calendar.get(Calendar.DAY_OF_MONTH); // 1-31
int month=calendar.get(Calendar.MONTH); //0-11
int year=calendar.get(Calendar.YEAR);