VB6.0 取 毫秒级 时间戳

  如题:先加载API

  要点:毫秒级时间戳只是在秒级时间戳后面多了当前时间得三位毫秒数。

  代码:

Public Declare Function timeGetTime Lib "winmm.dll" () As Long

Public Function GetUnixTime_ms() As String

  GetUnixTime_ms= DateDiff("s", "1970-1-1 0:0:0", DateAdd("h", -8, Now)) & Right(timeGetTime, 3)
End Function

posted @ 2018-05-11 11:10  PengRay  阅读(4361)  评论(0编辑  收藏  举报