Java tutorial
//package com.java2s; //License from project: Apache License import java.util.Calendar; import java.util.Locale; import android.text.format.DateFormat; public class Main { public static String getCurrentDate() { return DateFormat.format("yyyyMMdd_hhmmss", Calendar.getInstance(Locale.CHINA)).toString(); } }