Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default How to trigger a macro at regular intervals?

I have a workbook that is being updated through DDE links. I also want to
trigger the recalculation of a cell at regular intervals (every 5 seconds,
for example) while the DDE updates are happening. How can I do this? I tried
the Wait function in a macro, but this interrupts all updates. Any other
ideas?
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 486
Default How to trigger a macro at regular intervals?

You can give this a try. Place this in a standard code module...

Sub RefreshStuff()
MsgBox "Tada"
Application.OnTime Now + TimeValue("00:00:05"), "ReCalculate"

End Sub

sub ReCalculate()
application.calculate 'or calculatefull
end sub

--
HTH...

Jim Thomlinson


"ÉH" wrote:

I have a workbook that is being updated through DDE links. I also want to
trigger the recalculation of a cell at regular intervals (every 5 seconds,
for example) while the DDE updates are happening. How can I do this? I tried
the Wait function in a macro, but this interrupts all updates. Any other
ideas?

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,588
Default How to trigger a macro at regular intervals?

Look at

Application.OnTime

tim

--
Tim Williams
Palo Alto, CA


"ÉH" wrote in message
...
I have a workbook that is being updated through DDE links. I also want to
trigger the recalculation of a cell at regular intervals (every 5 seconds,
for example) while the DDE updates are happening. How can I do this? I

tried
the Wait function in a macro, but this interrupts all updates. Any other
ideas?



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35,218
Default How to trigger a macro at regular intervals?

Chip Pearson has lots of instructions at:
http://www.cpearson.com/excel/ontime.htm

ÉH wrote:

I have a workbook that is being updated through DDE links. I also want to
trigger the recalculation of a cell at regular intervals (every 5 seconds,
for example) while the DDE updates are happening. How can I do this? I tried
the Wait function in a macro, but this interrupts all updates. Any other
ideas?


--

Dave Peterson
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
macro trigger Leslieac Excel Discussion (Misc queries) 3 February 2nd 06 09:08 PM
Another way to trigger a macro? Leon[_5_] Excel Programming 1 December 22nd 05 06:03 AM
Coverting worksheet macro to regular macro wammer Excel Programming 3 July 31st 04 12:03 PM
Macro trigger? No Name Excel Programming 3 February 29th 04 05:24 PM
Macro trigger? excelguru Excel Programming 0 February 29th 04 06:10 AM


All times are GMT +1. The time now is 03:59 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"