Chcę tylko datę, aby pokazać się tak:Formatowanie daty kalendarzowej
Saturday, May 26, 2012 at 10:42 PM
Oto mój kod do tej pory:
Calendar calendar = Calendar.getInstance();
String theDate = calendar.get(Calendar.MONTH) + " " + calendar.get(Calendar.DAY_OF_MONTH) + " " + calendar.get(Calendar.YEAR);
lastclick.setText(getString(R.string.lastclick) + " " + theDate);
To pokazuje numery na miesiąc, dzień, i rok, ale czy jest lepszy sposób na zrobienie tego? Czy nie ma prostego sposobu robienia tego, jak używanie funkcji PHP date()
?
tak. nie rozumiem, dlaczego to jest takie trudne. – scarhand