Get System time in Milliseconds in android

Nit*_*der 4 java time android

Want to get time in milliseconds in android Ex 19:57:21:522.How do i do this?Could not find any straight forward API's to do so.

Sca*_*bat 12

试试SimpleDateFormat

http://docs.oracle.com/javase/6/docs/api/java/text/SimpleDateFormat.html

使用大写字母S的模式

SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss.SSS");
String currentDateandTime = sdf.format(new Date());
Run Code Online (Sandbox Code Playgroud)