1Calendar c = Calendar.getInstance();
2SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
3String strDate = sdf.format(c.getTime());
4Log.d("Date","DATE : " + strDate)
1String currentTime = new SimpleDateFormat("HH:mm:ss", Locale.getDefault()).format(new Date());
1String date = new SimpleDateFormat("yyyy-MM-dd", Locale.getDefault()).format(new Date());
1String currentDateTimeString = java.text.DateFormat.getDateTimeInstance().format(new Date());
2
3// textView is the TextView view that should display it
4textView.setText(currentDateTimeString);