LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #9   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,494
Default custom toolbar button questions

thanks, i'm just putting a macro button on each sheet. then they can click
on it when they want it.

--


Gary


"Tom Ogilvy" wrote in message
...
"Custom 1" was an example name of a custom floating commandbar.

Controls(3) referred to the 3rd control/button on that commandbar.

--
Regards,
Tom Ogilvy

"Gary Keramidas" <GKeramidasATmsn.com wrote in message
...
tried your idea, changed custom 1 to custom button (that's what it says

the
name is anyway), would not work. no name works other than button, but
that
works no matter what my custom button's name is.

i guess i just need a way to assign that code to the custom button on the
toolbar when the workbook opens.

--


Gary


"Tom Ogilvy" wrote in message
...
Code can't run userforms in other workbooks without taking
extraordinary
measures, so it should use the userform in that workbook.

tools=Customize,
This puts Excel in a design mode for commandbars. Leave the dialog
showing,
then go to your button and right click on it. Select Assign macro.
Change
the setting for what macro to run.


In code, you can do something like

Application.Commandbars("Custom 1").Controls(3).OnAction =
"MyWorkbooks.xls!MyMacro"

--
Regards,
Tom Ogilvy


"Gary Keramidas" <GKeramidasATmsn.com wrote in message
...
i created a user form in my master workbook. created a new macro
button
to
run it. i then exported the user form and imported it into the
client's
workbook. when i click the macro button, it opens my workbook and runs
the
form.

so, i have 2 questions:

1. how do i edit the custom button to assign which macro it runs?
ended
up
deleting it and creating a new one.

2. how do i specify in the code to run show the userform from the

current
workbook?

i tired thisworkbook.userform1.show and activeworkbook.userform1.show.



--


Gary











 
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
Custom toolbar button icons leaftye - ExcelForums.com Excel Discussion (Misc queries) 2 July 7th 05 06:09 PM
single button on a custom toolbar Randy Starkey Excel Programming 1 March 21st 05 05:42 PM
Assign macro to toolbar custom button? amescha Excel Programming 5 September 27th 04 05:31 PM
Delete a custom button by holding down the ALT key and dragging the button off the toolbar Stephen[_8_] Excel Programming 0 April 4th 04 02:22 PM
Can't delete custom button and toolbar Ron de Bruin Excel Programming 1 March 1st 04 09:46 PM


All times are GMT +1. The time now is 12:43 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"