Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Assign Macro to Custome Button Error!

I have multiple customized buttons that each use different macros. However I
keep having this problem where the buttons associate with a third macro
button. for example I have three buttons, one is called reprint, one is
updateaddins, and the last is BISCAL. for the last two buttons, everytime i
open excel they associate with "reprint.xla!updateaddins" and
"reprint.xla!biscal", when they should only associate with their respected
names, the add ins also do it with different excel spreadsheet names, or just
about anything and i cannot purposely recreate the error, it just happens.

The buttons are already present, so I just want to make sure that I assign
the correct macro name to the button. Here is the code I have, I keep getting
an error on the commandbars line. I am pretty sure the syntax is wrong, but I
cant seem to figure out how to make it work correctly since all examples talk
about adding the button and I already have the button...

If chkCtrlA.Value = True Then
AddIns("Ctr+lA Validate").Installed = False
AddIns.Add Filename:= _
"\\Server\Drivers & Applications\Add-Ins\Validate\Ctrl+A Validate.xla"
AddIns("Ctr+lA Validate").Installed = True
CommandBars("CtrlA").Controls(2).OnAction = "ctrla"
End If

any ideas would be great, i keep getting error '2147024809' the 'ctr+A
validate.xla!auto_add' cannot be found.

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
How to assign a macro to a button WANNABE Excel Programming 2 October 2nd 06 08:25 PM
How do I Assign Macro to a button? BellExcel Charts and Charting in Excel 4 May 20th 05 07:21 PM
Assign macro to button Bob Phillips[_6_] Excel Programming 0 May 24th 04 04:27 PM
Assign macro to button Frank Kabel Excel Programming 0 May 24th 04 04:03 PM
Assign button to run macro jamie85[_5_] Excel Programming 8 February 3rd 04 01:44 PM


All times are GMT +1. The time now is 04:55 AM.

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"