6、s Debug.Printcbar.Name,cbar.NameLocal,cbar.VisibleNextEndSub Private Sub Test() Dim i As Long Dim wordApp As New Word.Application Dim CBar As Office.CommandBar Dim CCtl As Office.CommandBarControl Set CBar = wordApp.CommandBars(
7、27) 'Bar Index For Each CCtl In CBar.Controls If CCtl.Id = 2041 Or CCtl.Id = 2604 Then '2041 Control ID CCtl.Enabled = False end if Next Set CBar = Nothing Set CCtl = Nothing Set wordApp = Nothing
8、 End Sub 这是屏蔽的方法,至于你要屏蔽的 Bar ID 是多少 Control ID 是多少看下面的 Word菜单一览表 CommandBar ID _ Control ID _ Control Caption Text11_2520_新建空白文档(&B) 1_23_打开(&O)... 1_3_保存(&S)