excel vba 下面这段代码啥意思? 答的好再追加10分悬赏。

Sub Macro1()

Dim intleft As Integer, introw As Integer
intleft = Application.CommandBars("Tick Mark").Width
introw = Application.CommandBars("Tick Mark").RowIndex
Application.CommandBars("Audit Utility").Left = intleft
Application.CommandBars("Audit Utility").RowIndex = introw

End Sub
我看应是这样,就是introw = Application.CommandBars("Tick Mark").RowIndex
Application.CommandBars("Audit Utility").RowIndex = introw这两个啥意思。这样能保证是同一行啊。 zipall要是说详细点就好了。

是下面这个贴子的内容?
http://club.excelhome.net/thread-326819-1-1.html
是VBA控制窗口工具位置
以下参考代码
Sub test()

'视图工具栏中,各种工具对应的英文名称

'worksheet menu bar表示工作表菜单栏

Application.CommandBars("worksheet menu bar").Enabled = False

'formatting表示格式工具栏

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

'standard表示常用工具栏

Application.CommandBars("Standard").Visible = falsae

'drawing表示绘图工具栏

Application.CommandBars("Drawing").Visible = False

'control toolbox表示控件工具箱

Application.CommandBars("Control Toolbox").Visible = False

'reviewing表示审阅工具

Application.CommandBars("Reviewing").Visible = False

Application.CommandBars("金山快译").Visible = False

'dispalyformulabar表示编辑栏

Application.DisplayFormulaBar = False

Application.CommandBars("Visual Basic").Visible = False

Application.CommandBars("Web").Visible = False

Application.CommandBars("Protection").Visible = False

Application.CommandBars("Borders").Visible = False

Application.CommandBars("Forms").Visible = False

Application.CommandBars("Formula Auditing").Visible = False

Application.CommandBars("Watch Window").Visible = False

'pivottable表示数据透视表

Application.CommandBars("PivotTable").Visible = False

'chart表示图表

Application.CommandBars("Chart").Visible = False

'picture表示图片

Application.CommandBars("Picture").Visible = False

Application.CommandBars("Exit Design Mode").Visible = False

'external data表示外部数据

Application.CommandBars("External Data").Visible = False

End Sub

别忘了在thisworkbook模块中加上下面的事件,用于还原菜单栏等

Private Sub Workbook_BeforeClose(Cancel As Boolean)

Application.CommandBars("worksheet menu bar").Enabled = True

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

Application.CommandBars("Standard").Visible = True

Application.CommandBars("Drawing").Visible = True

Application.CommandBars("Control Toolbox").Visible = True

Application.CommandBars("Reviewing").Visible = True

Application.CommandBars("金山快译").Visible = True

Application.DisplayFormulaBar = True

End Sub
温馨提示:答案为网友推荐,仅供参考
第1个回答  2011-01-05
根据第1个工具栏 tick mark的位置,将第2个工具栏audit utility放在它同行的左侧.本回答被提问者采纳
第2个回答  2011-01-05
高深了,我来学习的
相似回答