Fully customized datetime

suggest change
Date date = new Date();
SimpleDateFormat df = new SimpleDateFormat("HH:mm", Locale.US);
String localizedDate = df.format(date);

Locale.US fixes digits and markers to US conventions. Use Locale.getDefault() to follow the device locale.

Commonly used patterns:

Feedback about page:

Feedback:
Optional: your email if you want me to get back to you:



Table Of Contents