Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 16
Default Timer control

Hi,
I want to have a graph up dated ever 5 minute. I use this
macro
Sub Time_Control()

Begin:
' Start time
Time1 = Timer
' Wait 5 Minutes
Do While (Time1 + (5 * 60)) Timer
Loop
' Call macro
Call Update
' Stop after 1600 Hours
If (1600 * 60) Timer Then GoTo Begin

End Sub

it has two problems, you can't look at the graph while it
is running and it takes a lot of processor power to just
sit there ansd wait.

Thanks MarkS
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default Timer control

Mark,

Take a look at the OnTime method in VBA Help. This will allow you to forward
schedule a macro to run at 5 minute intervals, which can do the graph
update. It won't be as heavy, and will release the machine.

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

"Mark Scholes" wrote in message
...
Hi,
I want to have a graph up dated ever 5 minute. I use this
macro
Sub Time_Control()

Begin:
' Start time
Time1 = Timer
' Wait 5 Minutes
Do While (Time1 + (5 * 60)) Timer
Loop
' Call macro
Call Update
' Stop after 1600 Hours
If (1600 * 60) Timer Then GoTo Begin

End Sub

it has two problems, you can't look at the graph while it
is running and it takes a lot of processor power to just
sit there ansd wait.

Thanks MarkS



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
Process control chart for quality control in exel? Kara Charts and Charting in Excel 2 May 11th 10 05:45 PM
2007 Form Control/ActiveX Control font difference Nikko963 Excel Discussion (Misc queries) 0 April 15th 09 04:21 PM
Excel spin box - no Control tab in Format Control dialong box tocoau Excel Worksheet Functions 7 August 10th 08 03:15 PM
EXCEL TIMER CONTROL Avinash Shukla Links and Linking in Excel 0 June 28th 07 11:38 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 03:38 PM.

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

About Us

"It's about Microsoft Excel"