MSCRM online authentication
try
{
ClientCredentials cre = new ClientCredentials();
cre.UserName.UserName = "your user name";
cre.UserName.Password = "your passwod";
Uri serviceUri = new Uri("your Organizationservice.svc");
OrganizationServiceProxy proxy = new OrganizationServiceProxy(serviceUri, null, cre, null);
proxy.EnableProxyTypes();
IOrganizationService _service = (IOrganizationService)proxy;
}
catch (System.Web.Services.Protocols.SoapException ex)
{
}
{
ClientCredentials cre = new ClientCredentials();
cre.UserName.UserName = "your user name";
cre.UserName.Password = "your passwod";
Uri serviceUri = new Uri("your Organizationservice.svc");
OrganizationServiceProxy proxy = new OrganizationServiceProxy(serviceUri, null, cre, null);
proxy.EnableProxyTypes();
IOrganizationService _service = (IOrganizationService)proxy;
}
catch (System.Web.Services.Protocols.SoapException ex)
{
}
Comments
Post a Comment