#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 553
Default TOOLBAR FOR A MACRO

I need to make a button on a new TOOLBAR for starting a specific macro. How
to do the same?

All help shall be appreciated.

Thanx in advance.

--

Best Regards,
FARAZ A. QURESHI
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 553
Default TOOLBAR FOR A MACRO

The macro is actually a part of a collection of add-in codes in a file.
--

Best Regards,
FARAZ A. QURESHI


"FARAZ QURESHI" wrote:

I need to make a button on a new TOOLBAR for starting a specific macro. How
to do the same?

All help shall be appreciated.

Thanx in advance.

--

Best Regards,
FARAZ A. QURESHI

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,718
Default TOOLBAR FOR A MACRO

This is an example of creating a new button on the Worksheet menu bar. If
you wanted to use your own commandbar use the Commandbars.Add method.
Examples are in VBA Help and all over the web.

Sub AddBtn()
DelBtn
With CommandBars("Worksheet Menu Bar").Controls.Add(msoControlButton, ,
, , True)
.Caption = "CS_Override"
.TooltipText = "Mark/unmark selected range as override"
.OnAction = "MarkAsOverride"
.FaceId = 6743
.BeginGroup = True
End With
End Sub

Sub DelBtn()
On Error Resume Next
CommandBars("Worksheet Menu Bar").Controls("CS_Override").Delete
End Sub


--
Jim
"FARAZ QURESHI" wrote in message
...
| The macro is actually a part of a collection of add-in codes in a file.
| --
|
| Best Regards,
| FARAZ A. QURESHI
|
|
| "FARAZ QURESHI" wrote:
|
| I need to make a button on a new TOOLBAR for starting a specific macro.
How
| to do the same?
|
| All help shall be appreciated.
|
| Thanx in advance.
|
| --
|
| Best Regards,
| FARAZ A. QURESHI


  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default TOOLBAR FOR A MACRO

For additions to the worksheet menu bar, I really like the way John Walkenbach
does it in his menumaker workbook:
http://j-walk.com/ss/excel/tips/tip53.htm

Here's how I do it when I want a toolbar:
http://www.contextures.com/xlToolbar02.html
(from Debra Dalgleish's site)

And if you use xl2007:

If you want to learn about modifying the ribbon, you can start at Ron de Bruin's
site:
http://www.rondebruin.nl/ribbon.htm
http://www.rondebruin.nl/qat.htm -- For macros for all workbooks (saved as an
addin)
or
http://www.rondebruin.nl/2007addin.htm

In xl2007, those toolbars and menu modifications will show up under the addins.

FARAZ QURESHI wrote:

I need to make a button on a new TOOLBAR for starting a specific macro. How
to do the same?

All help shall be appreciated.

Thanx in advance.

--

Best Regards,
FARAZ A. QURESHI


--

Dave Peterson
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
Button with macro in toolbar Daniel Charts and Charting in Excel 1 August 25th 07 02:39 AM
macro in toolbar jatman Excel Discussion (Misc queries) 1 September 21st 06 08:25 AM
Custom Macro Toolbar? Wuddus Excel Discussion (Misc queries) 2 August 8th 06 03:30 PM
macro toolbar Ankur Excel Discussion (Misc queries) 3 August 5th 06 01:55 AM
Where is the resume macro on the toolbar? Bju23 Excel Discussion (Misc queries) 1 November 7th 05 08:53 PM


All times are GMT +1. The time now is 11:02 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"