A string containing the absolute path to the resource.
The Uri.AbsolutePath property contains the path information that the server uses to resolve requests for information. Typically this is the path to the desired information on the server's file system, although it also can indicate the application or script the server must run to provide the information.
The path information does not include the scheme, host name, or query portion of the URI.
The following example outputs the absolute path of a URI.
C# Example
using System; public class UriTest { public static void Main() { Uri myUri = new Uri ("http://www.contoso.com/URI/Hello%20World.htm?date=today", true); Console.WriteLine(myUri.AbsolutePath); } }
The output is
/URI/Hello%20World.htm