Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Run macro
Hi,
I have a macro in one workbook, that takes two parameters. For the sake of clarity, something like this: public sub TEST(pParam1 as string , pParam2 as string) Debug.print pParam1 & "," & pParam2 end sub In another workbook, I want to be able to: 1. Start a separate instance of Excel 2. Open the workbook. 3. Run TEST and pass in parameters I thought that ShellExecute might do the trick, as it has a "parameters" parameters - I thought this might be rather like the SubAddress named parameters for Application.FollowHyperlink. Incidentally, that works: Application.FollowHyperlink Address:="c:\FileToLoad.xls",SubAddress:="ThisWork book.TEST(""param1"",""param2"")" but I want a new instance of Excel, which this does not do. Any ideas/help anyone? |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Macro recorded... tabs & file names changed, macro hangs | Excel Worksheet Functions | |||
Macro Help Needed - Excel 2007 - Print Macro with Auto Sort | Excel Worksheet Functions | |||
how to count/sum by function/macro to get the number of record to do copy/paste in macro | Excel Programming | |||
macro to delete entire rows when column A is blank ...a quick macro | Excel Programming | |||
Start Macro / Stop Macro / Restart Macro | Excel Programming |