#1   Report Post  
Posted to microsoft.public.excel.misc,microsoft.public.excel.programming
external usenet poster
 
Posts: 107
Default Timer question


If I do

Range ("a1") = timer

on a loop then it refreshes showing fractions of a second, but shows
whatever large number the timer is at


However if i do


tim = Timer
Do

diff = Timer - tim
Range("a1") = diff

loop

then it counts up from zero, as intended, but for some reason drops all the
decimal places

Anyone know why it drops the decimals and how to make it keep the decimals?

Many thanks


  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1
Default Timer question


Check your other post


--
mikeaj72
------------------------------------------------------------------------
mikeaj72's Profile: http://www.thecodecage.com/forumz/member.php?userid=46
View this thread: http://www.thecodecage.com/forumz/sh...ad.php?t=44334

  #3   Report Post  
Posted to microsoft.public.excel.misc,microsoft.public.excel.programming
external usenet poster
 
Posts: 1,549
Default Timer question


tim and diff need to be declared as Single or Double.
Integer and Long carry no decimal places.
--
Jim Cone
Portland, Oregon USA



"teepee"
wrote in message
If I do
Range ("a1") = timer

on a loop then it refreshes showing fractions of a second, but shows
whatever large number the timer is at
However if i do
tim = Timer
Do
diff = Timer - tim
Range("a1") = diff
loop

then it counts up from zero, as intended, but for some reason drops all the
decimal places
Anyone know why it drops the decimals and how to make it keep the decimals?
Many thanks


  #4   Report Post  
Posted to microsoft.public.excel.misc,microsoft.public.excel.programming
external usenet poster
 
Posts: 107
Default Timer question

Thanks for the help


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
timer Steve[_9_] Excel Discussion (Misc queries) 4 January 28th 08 08:10 PM
Timer in VBA peyman Excel Discussion (Misc queries) 2 October 5th 07 06:53 PM
Timer Brandon H Excel Discussion (Misc queries) 5 August 9th 07 01:54 PM
Timer Vijay Excel Worksheet Functions 1 April 6th 07 11:00 AM
Stopping a Timer / Running a timer simultaneously on Excel Paul23 Excel Discussion (Misc queries) 1 March 10th 06 12:08 PM


All times are GMT +1. The time now is 07:55 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"