public Guid GetSiteID(string UserName, string Password, string Domain, string SiteURL)
{
Guid SiteGuid = Guid.Empty;
try
{
SiteData.SiteData site = new TP.WebService.SiteData.SiteDat
site.Url = SiteURL + "/_vti_bin/sitedata.asmx";
site.Credentials = new System.Net.NetworkCredential(
site.PreAuthenticate = true;
SiteData._sWebMetadata webMetaData;
SiteData._sWebWithTime[] arrWebWithTime;
SiteData._sListWithTime[] arrListWithTime;
SiteData._sFPUrl[] arrUrls;
string roles; string[] roleUsers; string[] roleGroups;
uint i = site.GetWeb(out webMetaData, out arrWebWithTime, out arrListWithTime, out arrUrls, out roles, out roleUsers, out roleGroups);
SiteGuid = new Guid(webMetaData.WebID);
}
catch (Exception)
{
}
return SiteGuid;
}