다음을 통해 공유


SPDatabaseSnapshotCollection.Item Property (Int32)

Gets the database snapshot at the specified indexed location in the collection of database snapshots.

Namespace:  Microsoft.SharePoint.Administration.Backup
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)

Syntax

'Declaration
Public ReadOnly Default Property Item ( _
    index As Integer _
) As SPDatabaseSnapshot
    Get
'Usage
Dim instance As SPDatabaseSnapshotCollection
Dim index As Integer
Dim value As SPDatabaseSnapshot

value = instance(index)
public SPDatabaseSnapshot this[
    int index
] { get; }

Parameters

Property Value

Type: Microsoft.SharePoint.Administration.Backup.SPDatabaseSnapshot
The database snapshot at the specified position in the collection of database snapshots.

Remarks

Warning

Database snapshots are typically created and deleted automatically by timer jobs in the background. To help ensure that the SPDatabaseSnapshotCollection object represents the current set of database snapshots, always call the RefreshSnapshots() method before you access or process any members of the collection. This point applies also when you access a database snapshot through an indexer. For example, if spd is an SPDatabase object, the line spd.Snapshots[0] should be preceded by a call of the RefreshSnapshots() method.

See Also

Reference

SPDatabaseSnapshotCollection Class

SPDatabaseSnapshotCollection Members

Item Overload

Microsoft.SharePoint.Administration.Backup Namespace