<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2600.0" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><STRONG>Stuart,</STRONG></DIV>
<DIV> </DIV>
<DIV> Could you kindly send me a copy of
ElapsedMicroSeconds() function mentioned by you?</DIV>
<DIV> </DIV>
<DIV>Regards,</DIV>
<DIV><STRONG>A.D.Tejpal</STRONG></DIV>
<DIV><STRONG>(<A
href="mailto:ad_tp@hotmail.com">ad_tp@hotmail.com</A>)</STRONG></DIV>
<DIV><STRONG>----------------------------</STRONG></DIV>
<BLOCKQUOTE
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV style="FONT: 10pt arial">----- Original Message ----- </DIV>
<DIV
style="BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: black"><B>From:</B>
<A title=stuart@lexacorp.com.pg href="mailto:stuart@lexacorp.com.pg">Stuart
McLachlan</A> </DIV>
<DIV style="FONT: 10pt arial"><B>To:</B> <A title=bchacc@san.rr.com
href="mailto:bchacc@san.rr.com">Rocky Smolin - Beach Access Software</A> ; <A
title=accessd@databaseadvisors.com
href="mailto:accessd@databaseadvisors.com">accessd@databaseadvisors.com</A>
</DIV>
<DIV style="FONT: 10pt arial"><B>Sent:</B> Tuesday, June 24, 2003 10:51</DIV>
<DIV style="FONT: 10pt arial"><B>Subject:</B> Re: [AccessD] Time in
milliseconds</DIV>
<DIV><BR></DIV>On 23 Jun 2003 at 21:08, Rocky Smolin - Beach Access S
wrote:<BR><BR>> Dear List:<BR>> <BR>> Is it possible to
access/store/display the time in increments smaller than seconds. I need
to time something in fractions of a second.<BR>> <BR><BR><BR>Short answer
- Yes.<BR><BR>Slightly longer answer - Yes but you can't use the built
in formatting functions.<BR><BR>Long answer - <BR><BR>It depends
on exactly what you are trying to do.<BR><BR><BR>Store:<BR>Dates and Times are
actually stored as doubles with the time as the fractional part so times can
certainly be stored to far <BR>greater accuracy than seconds.
<BR><BR>Display:<BR>To display fractional seconds within a date/time format,
you will need to roll your own formatting function since there is <BR>no
decimal seconds formatting character. <BR><BR>If you just want to display a
number of seconds, use a numeric variable for the number of seconds,
then you can format <BR>it to any precision you want ( or again roll your own
format by working in seconds and calcuating hours,minutes etc as
<BR>required)<BR><BR><BR>Measure:<BR>If you are trying to time events of a
reasonable duration. use the TIMER() function . It returns a double
representing the <BR>number of "ticks" elapsed sinced midnight. A tick is
approximately 1/18th sec. <BR><BR>For higher resolution, use the
GetTickCOunt() API function which *nominally* returns the number of
milliseconds since <BR>the system started. The actual resolution is dependant
on the particular system, you can determine what it is using the
<BR>GetSystemTimeAdjustment() API call, but it's normally good to about
1/100th sec<BR><BR>If you are timing short durations and need even high
accuracy, you can use the high-resolution performance counter<BR>(if your
machine has one) and get possibly better than millisecond and maybe even close
to microsecond accuracy<BR>(let me know if you want a copy of an
ElapsedMicroSeconds() function which uses the hrpc API calls.<BR>-- <BR>Stuart
McLachlan<BR>Lexacorp Ltd<BR>Application Development, IT
Consultancy<BR><A
href="http://www.lexacorp.com.pg">http://www.lexacorp.com.pg</A><BR></BLOCKQUOTE></BODY></HTML>