With ASP.NET it's quite easy to get absolute path to a page by calling the VirtualPathUtility.ToAbsolute method. Getting absolute URL is not that obvious but still quite easy. Just combine request url with absolute path to your ASP.NET page:
string absolutePath = VirtualPathUtility.ToAbsolute("~/test/MyWebForm.aspx");
Uri newUri = new Uri(Request.Url, absolutePath);
NICE, Very Nice
JP 12/15/2008 11:21:35 PM
Uri newUri = new UriBuilder(Request.Url.Scheme, Request.Url.Host, Request.Url.Port, absolutePath, aQueryMaybe).Uri;
murki 1/12/2010 11:53:59 PM