Is it possible to assign an Url.AbsoluteUri in ASP.NET?
Url.AbsoluteUri
No, this property is read-only.
You can create a new Uri though:
Uri
var url = new Uri("http://absoluteurl.example.com"); // url.AbsoluteUri is now "http://absoluteurl.example.com"
No, you canβt. But you can create a Uri with the AbsoluteUri desire by building one:
Uri url = new Uri("http://www.google.com");
No, you cannot, it is derived from a URI. See the MSDN documentation for Uri.AbsoluteUri .
Example from MSDN
Uri baseUri = new Uri("http://www.contoso.com"); Uri myUri = new Uri(baseUri,"catalog/shownew.htm?date=today");