次の方法で共有


SPGlobalAdmin.ExtendVirtualServer method (Uri, Boolean, String, Boolean, String, String, Boolean, Boolean)

NOTE: This API is now obsolete.

Use the SPWebApplicationBuilder class to create a new Web application instead. (In Windows SharePoint Services 2.0 the ExtendVirtualServer method extended an Internet Information Services (IIS) Web site with SharePoint Foundation, and is maintained for backward compatibility.)

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

Syntax

'Declaration
<ObsoleteAttribute("SPGlobalAdmin.ExtendVirtualServer is obsolete.  To create a new Web application, use the SPWebApplicationBuilder class.",  _
    False)> _
Public Function ExtendVirtualServer ( _
    uri As Uri, _
    bCreateNewAppPool As Boolean, _
    strAppPoolId As String, _
    bConfigurableAppPoolAccount As Boolean, _
    strAppPoolUserName As String, _
    strAppPoolPassword As String, _
    bAllowAnonymous As Boolean, _
    bEnsureNTLM As Boolean _
) As SPVirtualServer
'Usage
Dim instance As SPGlobalAdmin
Dim uri As Uri
Dim bCreateNewAppPool As Boolean
Dim strAppPoolId As String
Dim bConfigurableAppPoolAccount As Boolean
Dim strAppPoolUserName As String
Dim strAppPoolPassword As String
Dim bAllowAnonymous As Boolean
Dim bEnsureNTLM As Boolean
Dim returnValue As SPVirtualServer

returnValue = instance.ExtendVirtualServer(uri, _
    bCreateNewAppPool, strAppPoolId, _
    bConfigurableAppPoolAccount, strAppPoolUserName, _
    strAppPoolPassword, bAllowAnonymous, _
    bEnsureNTLM)
[ObsoleteAttribute("SPGlobalAdmin.ExtendVirtualServer is obsolete.  To create a new Web application, use the SPWebApplicationBuilder class.", 
    false)]
public SPVirtualServer ExtendVirtualServer(
    Uri uri,
    bool bCreateNewAppPool,
    string strAppPoolId,
    bool bConfigurableAppPoolAccount,
    string strAppPoolUserName,
    string strAppPoolPassword,
    bool bAllowAnonymous,
    bool bEnsureNTLM
)

Parameters

  • uri
    Type: System.Uri

    An absolute URI for the virtual server, which includes the host name, port number, and custom URL information. For example, if the URI is https://Server_Name:Port_Number/Sample_URL, when the virtual server is extended Sample_URL is included as part of the URL.

  • bCreateNewAppPool
    Type: System.Boolean

    true to create an application pool; otherwise, false.

  • strAppPoolId
    Type: System.String

    A string that specifies an ID for the application pool.

  • bConfigurableAppPoolAccount
    Type: System.Boolean

    true to indicate that the application pool account is configurable; otherwise, false.

  • strAppPoolUserName
    Type: System.String
    • A string that specifies a user name for the administrator account of the application pool. If true, specify one of the following values:

    • NetworkService

    • LocalService

    • LocalSystem

  • strAppPoolPassword
    Type: System.String

    A string that specifies a password for the administrator account of the application pool. The parameter is required only if the parameter is set to true.

  • bAllowAnonymous
    Type: System.Boolean

    true to allow anonymous access; otherwise, false.

  • bEnsureNTLM
    Type: System.Boolean

    true to use NTLM for authentication; otherwise, false. The default value is false.

Return value

Type: Microsoft.SharePoint.Administration.SPVirtualServer
An SPVirtualServer object that represents the extended virtual server.

See also

Reference

SPGlobalAdmin class

SPGlobalAdmin members

ExtendVirtualServer overload

Microsoft.SharePoint.Administration namespace