Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 23
Default Can I call a macro from ouside excel?

For example, I want to open the spreadsheet W.xls, and run the macro x()

I really want a string that looks something like

C:\Spreadsheets\W.xls #x#

That will open W.xls then run x()

Is this possible?
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1,726
Default Can I call a macro from ouside excel?

You could add the code to Workbook_Open, it will then automatically run when
you open the workbook


Private Sub Workbook_Open()

End Sub

'This is workbook event code.
'To input this code, right click on the Excel icon on the worksheet
'(or next to the File menu if you maximise your workbooks),
'select View Code from the menu, and paste the code

--
---
HTH

Bob

(change the xxxx to gmail if mailing direct)


"DannyS" wrote in message
...
For example, I want to open the spreadsheet W.xls, and run the macro x()

I really want a string that looks something like

C:\Spreadsheets\W.xls #x#

That will open W.xls then run x()

Is this possible?



  #3   Report Post  
Posted to microsoft.public.excel.misc
CLR CLR is offline
external usenet poster
 
Posts: 1,998
Default Can I call a macro from ouside excel?

Maybe put a InputBox in the WorkbookOpen macro and it will pop-up and ask for
user to input a MacroName as the file is opened............

Vaya con Dios,
Chuck, CABGx3




"DannyS" wrote:

For example, I want to open the spreadsheet W.xls, and run the macro x()

I really want a string that looks something like

C:\Spreadsheets\W.xls #x#

That will open W.xls then run x()

Is this possible?

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
Importing EXCEL Spreadsheets into ACCESS -- Macro or VBA? Excel Discussion (Misc queries) 0 July 12th 06 10:08 PM
Excel vba to call Access Macro ppyxl Excel Worksheet Functions 0 July 6th 06 02:42 PM
Excel vba to call Access Macro ppyxl Excel Discussion (Misc queries) 0 July 6th 06 02:41 PM
Closing File Error jcliquidtension Excel Discussion (Misc queries) 4 October 20th 05 12:22 PM
Button fails to call macro when open an Excel via Intranet tigertax Excel Discussion (Misc queries) 1 April 12th 05 10:21 AM


All times are GMT +1. The time now is 12:27 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"