StatusBarArray.SetIndex(StatusBar, Int16) 方法

定义

设置 StatusBar 中的初始 StatusBarArray 的索引。Sets the index of the initial StatusBar in a StatusBarArray.

public:
 void SetIndex(System::Windows::Forms::StatusBar ^ o, short Index);
public void SetIndex (System.Windows.Forms.StatusBar o, short Index);
member this.SetIndex : System.Windows.Forms.StatusBar * int16 -> unit
Public Sub SetIndex (o As StatusBar, Index As Short)

参数

o
StatusBar

控件数组中的 StatusBarA StatusBar in the control array.

Index
Int16

Short,表示指定的 StatusBar 的索引。A Short that represents the index of the specified StatusBar.

注解

SetIndex只应在控件数组中创建初始元素时调用方法。The SetIndex method should only be called when you are creating the initial element in the control array. 若要添加后续元素,请调用 Load 方法并指定 IndexTo add subsequent elements, call the Load method and specify the Index.

备注

Microsoft.VisualBasic.Compatibility.VB6 命名空间中的函数和对象用于工具从 Visual Basic 6.0 升级到 Visual Basic。Functions and objects in the Microsoft.VisualBasic.Compatibility.VB6 namespace are provided for use by the tools for upgrading from Visual Basic 6.0 to Visual Basic. 多数情况下,这些函数和对象可再现 .NET Framework 中其他命名空间的功能。In most cases, these functions and objects duplicate functionality that you can find in other namespaces in the .NET Framework. 只有当 Visual Basic 6.0 代码模型与 .NET Framework 实现有显著区别时,才必须使用这些函数和对象。They are necessary only when the Visual Basic 6.0 code model differs significantly from the .NET Framework implementation.

适用于