Method Syntax
The DisableOrganizationUsers method uses the following
syntax:
public string DisableOrganizationUsers(
string path,
string preferredDomainController,
bool sendCredentials)
Typical C# Usage
Typical usage for the DisableOrganizationUsers 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. DisableOrganizationUsers (path, preferredDomainController , sendCredentials);
// set the response XML to match the return from MPF
responseXml.LoadXml(response);
this.mpsResponse.Document = responseXml;
lblDone.InnerText = successMsg;