Method Syntax
The GetUserProperties method uses the following syntax:
public string GetUserProperties(
string path,
string preferredDomainController,
bool sendCredentials)
Typical C# Usage
Typical usage for the GetUserProperties method is as
follows:
//Get user name and password.
string userName = this.Request.ServerVariables.Get("AUTH_USER");
string pass = this.Request.ServerVariables.Get("AUTH_PASSWORD");
//Set credentials.
LiveCommunication.PreAuthenticate = true;
LiveCommunication.Credentials = new NetworkCredential(userName,pass);
lblMsg.InnerHtml = mpsResponseHeaderLabel;
//Display response.
this.mpsResponse.DocumentSource = "";
response = LiveCommunication.GetUserProperties(path,preferredDomainController, sendCredentials);
// set the response XML to match the return from MPF
responseXml.LoadXml(response);
this.mpsResponse.Document = responseXml;
lblDone.InnerText = successMsg;
Example XML Response
The following is an example of an XML response from the
GetUserProperties method:
<response>
<data>
<path>LDAP://CN=jimc@alpineskihouse.com,OU=alpineskihouse,
OU=consolidatedmessenger,OU=Hosting,DC=fabrikam,DC=Com</path>
<preferredDomainController>AD01.fabrikam.COM
</preferredDomainController>
<homeServerPool>[TBD - pool dn]</homeServerPool>
<federationEnabled>0</federationEnabled>
<internetAccessEnabled>0</internetAccessEnabled>
<archivingEnabled>1</archivingEnabled>
</data>
</response>