Creates a database snapshot of the current database.
Assembly: Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Return ValueType: Microsoft.SharePoint.Administration.Backup.SPDatabaseSnapshot
The database snapshot.
The method calls the RefreshSnapshots() method as part of its implementation.
If the EnabledManagement property has not been set to true or false, the method sets to true; otherwise, it does not change the value of the EnabledManagement property. Enabling management makes possible automatic database snapshot creation and deletion by using a SharePoint timer job based on the settings in the CreationInterval, MaximumRetention, and SnapshotLimit properties. You can set the EnabledManagement property to false after calling the method if you do not want this behavior. You would only have to do this after the first call of the method.