Condividi tramite


SPViewStyleCollection.Item Property (Int32)

Gets the view style object at the specified index in the collection.

Namespace:  Microsoft.SharePoint
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Available in Sandboxed Solutions: Yes
Available in SharePoint Online

Syntax

'Declaration
Public ReadOnly Property Item ( _
    iIndex As Integer _
) As SPViewStyle
    Get
'Usage
Dim instance As SPViewStyleCollection
Dim iIndex As Integer
Dim value As SPViewStyle

value = instance.Item(iIndex)
public SPViewStyle this[
    int iIndex
] { get; }

Parameters

  • iIndex
    Type: System.Int32

    A 32-bit integer that specifies the index.

Property Value

Type: Microsoft.SharePoint.SPViewStyle
An SPViewStyle object that represents the view style.

Remarks

To return a style, the Item property uses the index of the style in the collection, while the StyleByID() property uses the ID specified in the file VWSTYLES.XML.

This property throws an ArgumentOutOfRangeException exception if the specified index is outside the valid range of indexes for the collection.

In C#, this property is an indexer for the SharePointSPViewStyleCollection class.

See Also

Reference

SPViewStyleCollection Class

SPViewStyleCollection Members

Item Overload

Microsoft.SharePoint Namespace