LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 454
Default Run a Macro on Workbook Open Q

I wish to execute a Macro on opening up of an Excel file, but only if
the time the file is opened up is between 8:40am and 8:42am Mon-Fri
and 9:40am and 9:42am Sat-Sun.

My questions a

1) How would I do the above? I plan to open the file via Schedule
Task, so I've placed a 2 min window for opening, just in case between
the schedule task running and the file actually opening up, might take
longer than specifying an exact time eg 8:40 am and thus will mis the
execution of the macro.

2) Can I call a named macro, say Macro1 (that is within a normal
module) or do I have to enter all the code line by line, my code in
Macro1 also has several macros called within? I'm never sure on this
point if I have to re-enter the code line by line, I know if I do, it
will work, but will just calling the macro also work?

Thanks

 
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
Open workbook macro- find correct month to open? buzzharley[_10_] Excel Programming 8 July 8th 06 04:30 AM
open workbook from a macro and continue this macro afterwards Chris De Luyck Excel Programming 3 December 19th 05 12:12 PM
Open WorkBook & Run Macro Mike Fogleman Excel Programming 3 December 6th 05 06:56 PM
How to Run Macro in open workbook/s hni Excel Discussion (Misc queries) 1 October 31st 05 10:14 AM
how can I run a macro when I open a workbook? filo666 Excel Discussion (Misc queries) 2 March 2nd 05 07:56 PM


All times are GMT +1. The time now is 09:08 AM.

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"