Wednesday, 21 August 2013

How to get time in 12hr format from a long value in java

How to get time in 12hr format from a long value in java

I have a long value which have values as given bellow,
e.g. timeInLong = 1000 (which means 10:00 AM) timeInLong = 1337 (which
means 01:37 PM)
I need a smart way to convert above types of values and get time as
10:00AM and 01:37PM in string format.
Can someone please tell me how to do this?

No comments:

Post a Comment