At 3:23 PM -0500 16/4/06, D Jungk wrote:
Before I report this as a bug, would someone be willing to take a look to see
if i've made some obvious mistake.
http://www.flippingdades.com/rbstuff/TickError.zip
Using Linux, Ticks is reporting values 2.77 times too large.
In one button I have: StartTicks=Ticks
StartTicks is a "double" property of the window
In a second button I have:
StaticText1.text=Format( (Ticks - StartTicks)/60, "#.0")
Timing the interval roughly with a watch and also using Microseconds (which
works) I'm getting wrong answers. They are consistently 2.77 times too big.
Thanks,
DJ
Change it to:
dim tTicks, tMicroseconds as double
tTicks= Ticks
tMicroseconds = Microseconds
StaticText1.text=Format( (tTicks - StartTicks)/60, "#.0") + " ...
using Ticks"
StaticText2.text=Format( (tMicroseconds - Startmicros)/1000000,
"#.0") + " ... using Microseconds"
StaticText3.text="Ratio =
"+Format(Val(StaticText1.text)/Val(StaticText2.text), "#.00")
The calls to Format is expensive.
--
Cheers,
Dr Gerard Hammond
Bioinformatic Analyst
Garvan Institute of Medical Research, Sydney, Australia.
If you're not part of the solution, you're part of the precipitate.
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>