Just pulling stuff outta my code...
/* create a date format object that you like */
SimpleDateFormat tsFormat = new SimpleDateFormat("d MMM yyyy
HH:mm:ss");
/* get the time */
Calendar timeStamp = Calendar.getInstance();
/* convert that time to a string */
String ts = tsFormat.format(timeStamp.getTime());
That's it. Using this method you would end up with a string that looks
like this:
"1 Apr 2010 07:41:10"
Remember, most of this junk is just Java. There are gobs of
'cookbooks' out on the web for this sort of thing.
Ken H
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
To unsubscribe, reply using "remove me" as the subject.