Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
 
Posts: n/a
Default Automatically Refreshing Data at 12am

I want to set my worksheet that will always be open on my machine to
automatically refresh the data at 12am. Is the only way to do that with
a macro? If so, how do I go about that. Thanks!

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Bob Phillips
 
Posts: n/a
Default Automatically Refreshing Data at 12am

You can use OnTime to schedule a macro to run at a set time. See
http://www.cpearson.com/excel/ontime.htm

--

HTH

Bob Phillips

(remove nothere from the email address if mailing direct)

wrote in message
oups.com...
I want to set my worksheet that will always be open on my machine to
automatically refresh the data at 12am. Is the only way to do that with
a macro? If so, how do I go about that. Thanks!



  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
 
Posts: n/a
Default Automatically Refreshing Data at 12am

So I can do something like this?
Public RunWhen As Double


Sub StartTimer()

RunWhen = Time() = #12:00:00 AM# + TimeSerial(24, 0, 0)
Application.OnTime earliesttime:=RunWhen, procedu="The_Sub", _
schedule:=True
End Sub

Sub The_Sub()


ActiveWorkbook.RefreshAll
StartTimer

End Sub

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
From several workbooks onto one excel worksheet steve Excel Discussion (Misc queries) 6 December 1st 05 08:03 AM
DELETE DUPLICATE DATA IN A SHEET AUTOMATICALLY Sony Manoj Excel Discussion (Misc queries) 1 November 20th 05 08:39 AM
Automatically pasting worksheet data to new worksheet with formulas COntactJason Excel Worksheet Functions 0 August 10th 05 08:22 PM
Pasting data without the worksheet automatically delimiting it? NiallC Excel Discussion (Misc queries) 3 August 8th 05 09:23 AM
Line Graph Data Recognition Nat Charts and Charting in Excel 2 April 30th 05 02:07 PM


All times are GMT +1. The time now is 06:40 PM.

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"