If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Startup with a Macro
From a command line I need to start Excel, open a specific
Excel file, execute a macro in that file and then close the file with a save. This is to be done only at specific times and not every time I open the Excel file. Is there a command line option to start an Excel macro like the one they have in ACCESS. Any help would be appreciated. |
#2
|
|||
|
|||
Startup with a Macro
Hi
you could rename your macro to Auto_Open() or put the code in the workbook event workbook_oen() -----Original Message----- From a command line I need to start Excel, open a specific Excel file, execute a macro in that file and then close the file with a save. This is to be done only at specific times and not every time I open the Excel file. Is there a command line option to start an Excel macro like the one they have in ACCESS. Any help would be appreciated. . |
#3
|
|||
|
|||
Startup with a Macro
The Auto_Open executes the Macro when ever one opens the Excel file. At times I just need to open the Excel file and not have the macro executed. I haven't tried the workbook_open() yet. Thanks -----Original Message----- Hi you could rename your macro to Auto_Open() or put the code in the workbook event workbook_oen() -----Original Message----- From a command line I need to start Excel, open a specific Excel file, execute a macro in that file and then close the file with a save. This is to be done only at specific times and not every time I open the Excel file. Is there a command line option to start an Excel macro like the one they have in ACCESS. Any help would be appreciated. . . |
#4
|
|||
|
|||
Startup with a Macro
I'm not sure what you mean by "from the command line"? At
the time you want to execute this "open-run-close" sequence are you sitting looking at your spread sheet, or is this supposed to happen within a macro that's executing? If you are looking at the spreadsheet and decide tro initiate the sequence, are you willing to press a button (like one created with an AutoShape rectangle) that has a macro assigned to it? -----Original Message----- The Auto_Open executes the Macro when ever one opens the Excel file. At times I just need to open the Excel file and not have the macro executed. I haven't tried the workbook_open() yet. Thanks -----Original Message----- Hi you could rename your macro to Auto_Open() or put the code in the workbook event workbook_oen() -----Original Message----- From a command line I need to start Excel, open a specific Excel file, execute a macro in that file and then close the file with a save. This is to be done only at specific times and not every time I open the Excel file. Is there a command line option to start an Excel macro like the one they have in ACCESS. Any help would be appreciated. . . . |
#5
|
|||
|
|||
Startup with a Macro
This is what I am trying to do:
- I have a Workbook with a two macros that perform different actions on the same worksheet. - I need to schedule the execution of the macros at two different time T & T+X. - I am thinking of using Windows scheduler to do this. - At time T Scheduler executes "Open file - Execute Macro1 and Close file". - At time T+X Scheduler executes "Open file - Execute Macro2 and Close file". - The Macros are to be executed without any external interference. They are to be time triggered by the scheduler. -----Original Message----- I'm not sure what you mean by "from the command line"? At the time you want to execute this "open-run-close" sequence are you sitting looking at your spread sheet, or is this supposed to happen within a macro that's executing? If you are looking at the spreadsheet and decide tro initiate the sequence, are you willing to press a button (like one created with an AutoShape rectangle) that has a macro assigned to it? -----Original Message----- The Auto_Open executes the Macro when ever one opens the Excel file. At times I just need to open the Excel file and not have the macro executed. I haven't tried the workbook_open() yet. Thanks -----Original Message----- Hi you could rename your macro to Auto_Open() or put the code in the workbook event workbook_oen() -----Original Message----- From a command line I need to start Excel, open a specific Excel file, execute a macro in that file and then close the file with a save. This is to be done only at specific times and not every time I open the Excel file. Is there a command line option to start an Excel macro like the one they have in ACCESS. Any help would be appreciated. . . . . |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
word error | mac | General Discussions | 1 | May 6th, 2004 08:14 AM |
Macro | Nicole | Worksheet Functions | 4 | October 9th, 2003 09:53 PM |
Run a Macro at Startup | Dennis | Worksheet Functions | 5 | September 29th, 2003 08:49 PM |
applying macro to startup | David Webster | Worksheet Functions | 2 | September 29th, 2003 01:18 PM |