楼主 yjzstar |
如题,如何利用VBA对工具栏中各选项的显示及隐藏进行控制?具体如下: ' 格式 Application.CommandBars("formatting").Visible = False '隐藏 Application.CommandBars("formatting").Visible = True '显示 ' 常用 Range("C5").Select Application.CommandBars("Standard").Visible = False '隐藏 Application.CommandBars("Standard").Visible = True '显示 ' Visual Basic Application.CommandBars("Visual Basic").Visible = True '显示 Application.CommandBars("Visual Basic").Visible = False '隐藏 'Web工 Application.CommandBars("Web").Visible = True '显示 Application.CommandBars("Web").Visible = False '隐藏 '保护 Application.CommandBars("Protection").Visible = True '显示 Application.CommandBars("Protection").Visible = False '隐藏 '边框 Application.CommandBars("Borders").Visible = True '显示 Application.CommandBars("Borders").Visible = False '隐藏 '窗体 Application.CommandBars("Forms").Visible = False '隐藏 Application.CommandBars("Forms").Visible = True '显示 '公式审核 Application.CommandBars("Formula Auditing").Visible = True '显示 Application.CommandBars("Formula Auditing").Visible = False '隐藏 '绘图 Application.CommandBars("Drawing").Visible = True '显示 Application.CommandBars("Drawing").Visible = False '隐藏 '监视窗口 Application.CommandBars("Watch Window").Visible = True '显示 Application.CommandBars("Watch Window").Visible = False '隐藏 '控件工具箱 Application.CommandBars("Control Toolbox").Visible = True '显示 Application.CommandBars("Control Toolbox").Visible = False '隐藏 '列表 Application.CommandBars("List").Visible = True '显示 Application.CommandBars("List").Visible = False '隐藏 '审阅 Application.CommandBars("Reviewing").Visible = True '显示 Application.CommandBars("Reviewing").Visible = False '隐藏 '数据透视表 Application.CommandBars("PivotTable").Visible = True '显示 Application.CommandBars("PivotTable").Visible = False '隐藏 '图表 Application.CommandBars("Chart").Visible = True '显示 Application.CommandBars("Chart").Visible = False '隐藏 '图片 Application.CommandBars("Picture").Visible = True '显示 Application.CommandBars("Picture").Visible = False '隐藏 '艺术字 Application.CommandBars("WordArt").Visible = True '显示 Application.CommandBars("WordArt").Visible = False '隐藏 |
2楼 xyf2210 |
学习个 |
3楼 lnt1231 |
围观**的杰作 |