LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 76
Default Changing Ribbon buttons

I want my Excel 2007 "Comma Style" and "Percent Style" buttons to work
differently than the default.

I have put the following code in PERSONAL.XLSB.

Sub CommaStyleChange()
Application.CommandBars.FindControl(ID:=397).OnAct ion = MyCommaStyle
End Sub
---------------
Sub MyCommaStyle()
ActiveCell.NumberFormat = "#,##0" 'I don't want decimals or a
leading/trailing space for parenthesis
End Sub

The "Comma Style" button still changes the format to Excel's standard. How
do I get this to work for me everytime I use Excel? Also, since I will want
to do the same for Percent, can someone find the ID number for that?
--
Thank you, Brad E.
 
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
Not all Ribbon Buttons are available in Excel 2007 Bill Excel Discussion (Misc queries) 4 May 14th 09 03:47 PM
The Developer Ribbon Tab - buttons inactive Darlove Excel Programming 1 July 28th 08 03:41 PM
QAT Buttons and Ribbon Issues in Excel 2007 Ailish Excel Discussion (Misc queries) 1 May 9th 08 06:02 PM
changing the order of the ribbon button Craig Excel Discussion (Misc queries) 1 April 28th 08 10:14 PM
Excel 2007 Ribbon Check custom buttons Alice[_7_] Excel Programming 6 April 22nd 07 01:58 PM


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