View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Andy Pope Andy Pope is offline
external usenet poster
 
Posts: 2,489
Default Ron de Bruin's instructions on Excel 2007 ribbon

Hi,

You need to change the code.
See Ron's page. http://www.rondebruin.nl/ribbon.htm

For onAction="Macro1" it will create this for you.

Sub Macro1(control as IRibbonControl)
ActiveWindow.DisplayOutline = False
End Sub

Cheers
Andy

--

Andy Pope, Microsoft MVP - Excel
http://www.andypope.info
"rupert" wrote in message
...
I've followed Ron de Bruin's instructions on Excel 2007 ribbon using
"Office
2007 Custom UI editor" based on the first of Ron's
samples(http://www.rondebruin.nl/xmlribbongroups.htm) and used the first
sample to assign buttons to a couple of simple macros to Custom button 1 &
2
repsectively. The VBA works fine to show/hide outline. So I cant see why
the
Custom ribbon buttons wont work. No doubt I'm being thick but there seems
to
be a disconnect between adding these custom button to the ribbon and
actually
assigning a macro.

Sub Macro1()
ActiveWindow.DisplayOutline = False
End Sub

Sub Macro2()
ActiveWindow.DisplayOutline = True
End Sub

When I click on the buttons, I get error message saying "wrong number of
arguments or invalid property assignment". I am trying to replicate a
button
missing from Excel 2007 to show/hide outline when grouping rows. Please
could
you help.