DesignerAutoFormatCollection.Item[Int32] 属性

定义

获取或设置集合中指定索引处的 DesignerAutoFormat 对象。Gets or sets a DesignerAutoFormat object at the specified index in the collection.

public:
 property System::Web::UI::Design::DesignerAutoFormat ^ default[int] { System::Web::UI::Design::DesignerAutoFormat ^ get(int index); };
public System.Web.UI.Design.DesignerAutoFormat this[int index] { get; }
member this.Item(int) : System.Web.UI.Design.DesignerAutoFormat
Default Public ReadOnly Property Item(index As Integer) As DesignerAutoFormat

参数

index
Int32

要在集合中获取或设置的 DesignerAutoFormat 的从零开始的索引。The zero-based index of the DesignerAutoFormat to get or set in the collection.

属性值

DesignerAutoFormat

位于集合中指定索引处的 DesignerAutoFormatThe DesignerAutoFormat at the specified index in the collection.

例外

index 小于零。index is less than zero.

- 或 --or- index 大于 Count 属性。index is greater than the Count property.

注解

使用 Item[] 索引器检索 DesignerAutoFormat 集合中指定索引处的对象,或设置集合中指定索引处的格式。Use the Item[] indexer to retrieve the DesignerAutoFormat object at the specified index within the collection or to set the format at the specified index within the collection. 可以通过使用数组表示法来索引集合中的元素。You can index elements in the collection by using array notation. 例如,你可以 i 使用 AutoFormats(i) Microsoft 标志或 c # 的表示法在 index 处为元素编制索引 AutoFormats[i]For example, you can index an element at index i with the notation AutoFormats(i) for Microsoft VisualBasic or AutoFormats[i] for C#.

如果具有对对象的引用 DesignerAutoFormat 并需要集合中对象的索引,请使用 IndexOf 方法。When you have a reference to the DesignerAutoFormat object and need the index of the object in the collection, use the IndexOf method.

适用于

另请参阅