Application.ApplicationPoolName Property

 

Gets or sets the name of the application pool that the application is assigned to.

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

public string ApplicationPoolName { get; set; }

Property Value

Type: System.String

The name of the application pool that the application is assigned to.

Each site can have a default application pool configured. If an application pool is not explicitly set for the application, the ApplicationPoolName property returns the default application pool name configured for the site. Use the Site.ApplicationDefaults property to view the default settings for a site.

The following example reads the configuration settings for an existing Application. The code displays the value returned from the ApplicationPoolName property for the applications configured under the "Default Web Site".

The following example creates a new ApplicationPool and then creates a new application that is assigned to the newly created ApplicationPool.

Return to top
Show: