View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
al al is offline
external usenet poster
 
Posts: 64
Default Right click - Normal view/ Page break preview

The macro below is only working if the activesheet is in "normal
view" but not when in "page break preview" - could someone pls amend
the macro to make it works in both status.thxs


Sub auto_open()

Application.CommandBars("Cell").Reset
With Application.CommandBars("Cell").Controls

With .Add
.Caption = "Close"
.OnAction = ThisWorkbook.Name & "!CloseBook"
.Tag = cControlTag
.BeginGroup = True
End With



End With

End Sub