Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi,
I'm using VB 6.3 with Excel 2000 in Win2000. I am trying to create menu items that call procedures in modules. The procedures have arguments, for example Sub DoSomeThing(Arg1 As String, Arg2 As Boolean) When creating the menu item, I have a pretty arcane attempt... Set SubMenuItem = MenuItem.Controls.Add _ (Type:=msoControlButton) With SubMenuItem .Caption = "Process File" .Tag = "blah" '.OnAction = "'Module1.DoSomeThing """ & .Tag & """ False'" End With (picked this up from newsgroup but don't quite get it) The message back is The macro "C:\temp\ThisFile.xls'!'Module1.DoSomeThing "blah" False" cannot be found. Any ideas? Thanks in advance, Max |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Macro - onAction arguments | Excel Worksheet Functions | |||
How do you add arguments to an OnAction event? | Excel Programming | |||
OnAction | Excel Programming | |||
.OnAction - Multiple Calls | Excel Programming | |||
OnAction | Excel Programming |