Wednesday, April 29, 2009

Get System Time Adjustment

'Get System Time Adjustment



Private Declare Function GetSystemTimeAdjustment
Lib "kernel32" _

(lpTimeAdjustment As Long, lpTimeIncrement As Long, _

lpTimeAdjustmentDisabled As Boolean) As Long



Private Sub Form_Load()

Dim RetAdd As Long, RetInterval As Long, RetAdjust
As Boolean

GetSystemTimeAdjustment RetAdd, RetInterval, RetAdjust



If RetAdjust Then

MsgBox "Periodic time adjustment is disabled!", _

vbInformation

Else

MsgBox "Every " + CStr(RetInterval) + _

"x100 nanoseconds, the computer adds " + CStr(RetAdd) + _

"x100 nanoseconds to your time-of-day clock.", _

vbInformation

End If



End Sub



 

No comments:

Post a Comment