hi that is not working. Because the return type of format() is string ,but i want the return type to be Date object.So to convert the string to Date if i use parse then again the output is in hh:mm:ss format,but i wanted it to be in hh:mm format.
I'm a little confused. "Format" doesn't make sense for a Date object. Dates are only formatted when they become string representations of Dates. So the return type should be a String.
Perhaps what you want is to set the seconds of the date to zero? To do that, take a look at the Calendar class.
Piscis Babelis est parvus, flavus, et hiridicus, et est probabiliter insolitissima raritas in toto mundo.
Barry's not gonna like this. Barry's not gonna like this one bit. What is Barry's deal with tiny ads?