SPContentDatabase.IsAttachedToFarm Property

Gets a value that indicates whether the content database is attached to the farm.

Namespace:  Microsoft.SharePoint.Administration
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Available in Sandboxed Solutions: No

Syntax

'Declaration
Public ReadOnly Property IsAttachedToFarm As Boolean
    Get
'Usage
Dim instance As SPContentDatabase
Dim value As Boolean

value = instance.IsAttachedToFarm
public bool IsAttachedToFarm { get; }

Property Value

Type: System.Boolean
true if the database is attached; otherwise false.

Remarks

The IsAttachedToFarm property is false if, and only if, the SPContentDatabase object was created by a call of the CreateUnattachedContentDatabase() method.

See Also

Reference

SPContentDatabase Class

SPContentDatabase Members

Microsoft.SharePoint.Administration Namespace