Can a macro exist and run on its own outside of a spreadsheet? I wrote a
program that I'd like to run from, say, my Desktop rather than opening a
spreadsheet and clicking a button. Any ideas?
Thanks, Matthew
Can a macro exist and run on its own outside of a spreadsheet? I wrote a
program that I'd like to run from, say, my Desktop rather than opening a
spreadsheet and clicking a button. Any ideas?
Thanks, Matthew
Excel macros can only run in Excel. You might be able to convert your
code to a VBscript routine: all depends on what it does....
Tim.
"Pflugs" <[email protected]> wrote in message
news:[email protected]...
> Can a macro exist and run on its own outside of a spreadsheet? I
> wrote a
> program that I'd like to run from, say, my Desktop rather than
> opening a
> spreadsheet and clicking a button. Any ideas?
>
> Thanks, Matthew
>
You should be able to do anything from VBScript, but it will require opening
an instance of Excel. Once you have a reference to an Excel object, you will
have the same options.
Here is a very trivial example that should be saved as a .vbs file and then
just launched
Dim xlApp
Set xlApp = CreateObject("Excel.Application")
xlApp.Workbooks.Add
MsgBox xlApp.ActiveWorkbook.Name
xlApp.Quit
Set xlApp = Nothing
--
HTH
Bob Phillips
"Pflugs" <[email protected]> wrote in message
news:[email protected]...
> Can a macro exist and run on its own outside of a spreadsheet? I wrote a
> program that I'd like to run from, say, my Desktop rather than opening a
> spreadsheet and clicking a button. Any ideas?
>
> Thanks, Matthew
>
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks