WebDirectorySetting Class

MSBuild

Reads and modifies a web directory configuration setting.


Namespace: MSBuild.Community.Tasks.IIS
Assembly: MSBuild.Community.Tasks (in MSBuild.Community.Tasks.dll)

Syntax

Visual Basic (Declaration)
Public Class WebDirectorySetting
    Inherits WebBase
C#
public class WebDirectorySetting : WebBase
C++
ref class WebDirectorySetting : WebBase
J#
public class WebDirectorySetting extends WebBase
JScript
public class WebDirectorySetting extends WebBase

Example

Display the file system path of the MyWeb web directory:

 Copy Code
            <WebDirectorySetting VirtualDirectoryName="MyWeb" SettingName="Path">
                <Output TaskParameter="SettingValue" PropertyName="LocalPath" />
            </WebDirectorySetting>
            <Message Text="MyWeb is located at $(LocalPath)" />
            
Set the default document for the MyWeb directory to Default.aspx:
 Copy Code
            <WebDirectorySetting VirtualDirectoryName="MyWeb" SettingName="DefaultDoc" SettingValue="Default.aspx" />
            <WebDirectorySetting VirtualDirectoryName="MyWeb" SettingName="EnableDefaultDoc" SettingValue="True" />
            

Inheritance Hierarchy

System.Object
   Microsoft.Build.Utilities.Task
      MSBuild.Community.Tasks.IIS.WebBase
         MSBuild.Community.Tasks.IIS.WebDirectorySetting

Thread Safety

Public static (Shared in Visual Basic)staticShared members of this type are safe for multithreaded operations. Instance members are not guaranteed to be thread-safe.

See Also

Syntax based on .NET Framework version 2.0.
Documentation version 1.0.0.0.