Re: Help me
Re: Help me
- Subject: Re: Help me
- From: Paul Berkowitz <email@hidden>
- Date: Mon, 17 Dec 2001 23:24:16 -0800
On 12/17/01 10:51 PM, "David Wignall" <email@hidden> wrote:
>
Create the VB macro as usual and then call it from your script with the line
>
>
RunMacro "(MacroName)"
>
>
> Thanks to all, bye !
>
>
No worries. Hope I helped
In Excel X there is no 'RunMacro' command in the Dictionary. Nor 'Do
Script'. But 'Evaluate' is still there. I believe you still need the
exclamation point after the Workbook path and before the macro name:
Evaluate "WorkbookName!MacroName(value)"
You can even get a result back if you've written the macro as a Function()
rather than as a Sub(), which allows you to pass that 'value' parameter.
(Otherwise, if it's a Sub and no result is needed, and no value inserted in
the parentheses.)
(There is a RunAutoMacros command, but that just applies to the four
commands that can be automatically run at startup.)
--
Paul Berkowitz
References: | |
| >Re: Help me (From: David Wignall <email@hidden>) |