IDeploymentContext.SiteUrl Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Returns the canonical URL of the Microsoft.SharePoint.SPWeb that the project is connected to, according to SharePoint.
public:
Uri ^ SiteUrl();
public Uri SiteUrl ();
abstract member SiteUrl : unit -> Uri
Public Function SiteUrl () As Uri
Returns
The canonical URL of the Microsoft.SharePoint.SPWeb that the project is connected to, according to SharePoint.
Remarks
This may or may not be identical to Microsoft.VisualStudio.SharePoint.ISharePointProject.SiteUrl, but they point to the same resource.
This value is queried from SharePoint so that it is consistent with SiteCollectionUrl.
For example, the Microsoft.VisualStudio.SharePoint.ISharePointProject.SiteUrl may be http://localhost, but SharePoint will resolve it to http://hostname.