Display date _and_ time in user locale

Posted by Sverre Rabbelier on Stack Overflow See other posts from Stack Overflow or by Sverre Rabbelier
Published on 2010-06-06T10:47:16Z Indexed on 2010/06/06 10:52 UTC
Read the original article Hit count: 286

Filed under:
|
|

I know I can use android.text.format.DateFormat.getDateFormat() to format my dates, and android.text.format.DateFormat.getTimeFormat to format my times, but how do I format a datetime? Similar to the getDateTimeInstance method from java.text.DateFormat.

I'm currently just concatenating the result of both the getDateFormat and getTimeFormat's formatters, but I don't know which way around the user prefers to have their dates and times shown.

© Stack Overflow or respective owner

Related posts about android

Related posts about datetime