WebContext.Path Property

 
System_CAPS_noteNote

The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

Gets the current virtual path of the Web application.

Namespace:   System.Web.Configuration
Assembly:  System.Web (in System.Web.dll)

public string Path { get; }

Property Value

Type: System.String

The current virtual path of the Web application.

The following example shows how to use the Path property. This code example is part of a larger example provided for the WebContext class.

// WebContext - Path.
Console.WriteLine("Path: {0}", webContext.Path.ToString());

.NET Framework
Available since 2.0
Return to top
Show: