本主题中的某些内容可能不适用于某些语言。
 Move 方法应用于 CommandBarButton、CommandBarComboBox、CommandBarControl 和 CommandBarPopup 对象的情形。
Move 方法应用于 CommandBarButton、CommandBarComboBox、CommandBarControl 和 CommandBarPopup 对象的情形。
将“Office 助手”移动到指定位置。
expression.Move(xLeft, yTop)
expression 必需。该表达式返回一个 Assistant 对象。
xLeft Integer 类型,必需。以点数表示的“Office 助手”窗口左端位置。
yTop Integer 类型,必需。以点数表示的“Office 助手”窗口顶端位置。
 应用于 CommandBarButton、CommandBarComboBox、CommandBarControl 和 CommandBarPopup 对象的情形。
应用于 CommandBarButton、CommandBarComboBox、CommandBarControl 和 CommandBarPopup 对象的情形。
本示例将名为 Custom 的命令栏上的第一个组合框控件移动到该命令栏上的第七个控件之前。本示例设置标记为 "Selection box" 并赋予控件较低的优先级,以便在一行容纳不下所有控件时将其隐藏。
Set allcontrols = CommandBars("Custom").Controls
For Each ctrl In allControls
    If ctrl.Type = msoControlComboBox Then
        With ctrl
            .Move Before:=7
             .Tag = "Selection box"
             .Priority = 5
         End With
         Exit For
    End If
Next本示例在指定位置显示“Office 助手”,并在使其可见之前设置多个选项。
With Assistant
    .Reduced = True
    .Move xLeft:= 400, yTop:= 300
    .MoveWhenInTheWay = True
    .TipOfDay = True
    .Visible = True
    .Animation = msoAnimationGreeting
End With