Timestamp

I need time stamp information, i m currently using KeQuerySystemTime() but it always gives me zero, any ideas of some other API i can use?

Post your code. You most probably want KeQueryPerformanceCounter() which will give you a finer granularity

d

-----Original Message-----
From: xxxxx@lists.osr.com [mailto:xxxxx@lists.osr.com] On Behalf Of xxxxx@gmail.com
Sent: Thursday, March 29, 2012 3:24 PM
To: Windows System Software Devs Interest List
Subject: [ntdev] Timestamp

I need time stamp information, i m currently using KeQuerySystemTime() but it always gives me zero, any ideas of some other API i can use?


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer

LARGE_INTEGER TimeStamp;
KeQuerySystemTime(&TimeStamp);

How are you checking the result? With a DbgPrint (“%d/%x”)? looking at it with the debugger? Remember it is a 64, not 32 bit, value, so %d/%x is only going to show you the upper 32 bits, which are probably zero.

d

-----Original Message-----
From: xxxxx@lists.osr.com [mailto:xxxxx@lists.osr.com] On Behalf Of xxxxx@gmail.com
Sent: Thursday, March 29, 2012 3:47 PM
To: Windows System Software Devs Interest List
Subject: RE:[ntdev] Timestamp

LARGE_INTEGER TimeStamp;
KeQuerySystemTime(&TimeStamp);


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer