SPGlobalAdmin.CreateConfigDatabase Method (String, String, String, String, Boolean, Boolean, String, String)
NOTE: This API is now obsolete.
Use the Create() method of the SPFarm class to create a configuration database instead. (In Windows SharePoint Services 2.0, the CreateConfigDatabase method was used to create a configuration database based on the specified database server, database name, user name, password, account information for Active Directory Domain Services (AD DS), and a Boolean value that specifies whether to use the host header as the name for a site, and is maintained for backward compatibility.)
Namespace: Microsoft.SharePoint.Administration
Assembly: Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Available in Sandboxed Solutions: No
Syntax
'Declaration
<ObsoleteAttribute("Use SPFarm.Create instead.")> _
Public Function CreateConfigDatabase ( _
strDatabaseServer As String, _
strDatabaseName As String, _
strUserName As String, _
strPassword As String, _
bHostHeaderAsSiteName As Boolean, _
bIsADMode As Boolean, _
strADDomain As String, _
strADOU As String _
) As SPConfigDatabase
'Usage
Dim instance As SPGlobalAdmin
Dim strDatabaseServer As String
Dim strDatabaseName As String
Dim strUserName As String
Dim strPassword As String
Dim bHostHeaderAsSiteName As Boolean
Dim bIsADMode As Boolean
Dim strADDomain As String
Dim strADOU As String
Dim returnValue As SPConfigDatabase
returnValue = instance.CreateConfigDatabase(strDatabaseServer, _
strDatabaseName, strUserName, strPassword, _
bHostHeaderAsSiteName, bIsADMode, _
strADDomain, strADOU)
[ObsoleteAttribute("Use SPFarm.Create instead.")]
public SPConfigDatabase CreateConfigDatabase(
string strDatabaseServer,
string strDatabaseName,
string strUserName,
string strPassword,
bool bHostHeaderAsSiteName,
bool bIsADMode,
string strADDomain,
string strADOU
)
Parameters
strDatabaseServer
Type: System.StringA string that specifies the database server.
strDatabaseName
Type: System.StringA string that contains the name of the new database.
strUserName
Type: System.StringA string that contains the user name to use for the administrator account. This parameter is required only if SQL authentication is used.
strPassword
Type: System.StringA string that specifies a password for the administrator account. This parameter is required only if SQL authentication is used.
bHostHeaderAsSiteName
Type: System.Booleantrue to use the host name as the site name; otherwise, false.
bIsADMode
Type: System.Booleantrue to automatically create accounts in AD DS when a site is created; otherwise, false.
strADDomain
Type: System.StringA string that specifies an Active Directory domain.
strADOU
Type: System.StringA string that specifies an Active Directory organizational unit.
Return Value
Type: Microsoft.SharePoint.Administration.SPConfigDatabase
An SPGlobalConfig object.
Remarks
To use this method, accounts must be created with permissions to a specified Active Directory domain and organizational unit.