View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
Ron de Bruin Ron de Bruin is offline
external usenet poster
 
Posts: 11,123
Default Running a macro in another workbook

Hi Blue

will this still work?

No

If you want to use the macro in all your workbooks you can copy the macro in
your personal.xls.
This is a (normal) hidden workbook that is loaded automatically by Excel.
When you record a macro, you have the option of recording it to your
Personal Macro Workbook.
The file, Personal.xls, is stored in your \XLStart directory.

The easiest is to record a dummy macro and choose Personal Macro Workbook.
Excel create the file for you this way.
Then copy your macro in this file and delete the dummy macro.





--
Regards Ron de Bruin
http://www.rondebruin.nl


"Blue" wrote in message . ..
Ron

Thanks for the reply, the workbook with the macro in will be closed, will
this still work?

Blue
"Ron de Bruin" wrote in message
...
Use Application.run to call a macro in a other open workbook
Some notes on this from Chip Pearson

Application.Run "Book1.xls!MacroName"

Or, if the book name contains spaces, (watch the quotes)

Application.Run "'Book One.xls'!MacroName"


--
Regards Ron de Bruin
http://www.rondebruin.nl


"Blue" wrote in message

.. .
I have a workbook called "blank" that has a macro in it called "report".

I
want to call the "report" macro from several other workbooks and copy

the
results back to the workbook/sheet that asked the "report" macro to run.

Thanks for your help

Blue