Answers for "kotlin get time milis hour minutes"

1

kotlin get time milis hour minutes

fun getTimeWithMilis(millis: Long): String {
        val date = Date(millis)

        val formatter = SimpleDateFormat("HH:mm")
        formatter.timeZone = TimeZone.getTimeZone("UTC")

        val formatted = formatter.format(date)
        Log.d("Time : ",formatted)
        return formatted.toString();

    }
Posted by: Guest on October-21-2021

Code answers related to "kotlin get time milis hour minutes"

Browse Popular Code Answers by Language