how to Delete Format Menu Toolbar From Excel

  • Thread starter Thread starter vicky
  • Start date Start date
V

vicky

I need a code thru which i need to remove Format Toolbar . i.e the
user shuld not be able to have access to Format toolbar ...
 
Sub BarVis(bVis As Boolean)

Application.CommandBars("Formatting").Visible = bVis

End Sub

Regards,
Peter T
 
thanks a lot . i just need to de - activate the sheet option in format
menu bar . this line de-activates whole format menu bar
Application.CommandBars.FindControl(ID:=30026).Enabled = True
 
Try

Sub Enabled_False()
Dim Ctl As CommandBarControl

On Error Resume Next
For Each Ctl In Application.CommandBars.FindControl(ID:=30006).Controls
Ctl.Enabled = False
Next Ctl
Application.CommandBars.FindControl(ID:=30026).Enabled = True
On Error GoTo 0
End Sub


Sub Enabled_True()
Dim Ctl As CommandBarControl

On Error Resume Next
For Each Ctl In Application.CommandBars.FindControl(ID:=30006).Controls
Ctl.Enabled = True
Next Ctl
On Error GoTo 0
End Sub
 
Back
Top