Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

HttpRequest.ApplicationPath Property

Gets the ASP.NET application's virtual application root path on the server.

[Visual Basic]
Public ReadOnly Property ApplicationPath As String
[C#]
public string ApplicationPath {get;}
[C++]
public: __property String* get_ApplicationPath();
[JScript]
public function get ApplicationPath() : String;

Property Value

The virtual path of the current application.

Example

The following example assigns the virtual application root path for the current URL request to a string variable.

[Visual Basic] 
Dim Path As String
 Path = Request.ApplicationPath
   

[C#] 
String Path;
 Path = Request.ApplicationPath;
   

[C++] 
String* Path;
 Path = Request->ApplicationPath;
   

[JScript] 
var path : String = Request.ApplicationPath

Requirements

Platforms: Windows 2000, Windows XP Professional, Windows Server 2003 family

See Also

HttpRequest Class | HttpRequest Members | System.Web Namespace

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft. All rights reserved.