In CRM 2015, we developed custom code to access Organization service to retrieve/update CRM Org entities with the following code.
string connection = @"ServiceUri=">crmorg.mycrmtest.ourdomain.com;Username=domain\admin;Password=XXXXXXX;";
try
{
CrmConnection crmConnect = CrmConnection.Parse(connection);
crmConnect.ProxyTypesEnabled = true;
crmConnect.Timeout = new TimeSpan(0, 0, 60, 0);
CachedOrganizationService orgService = new CachedOrganizationService(crmConnect);
return orgService;
}
catch (Exception ex)
{
new LogService().Log(Constants.LOG_ERROR, new Error("An error occured while connecting to CRM", ex));
}
return null;
However, when I connect this custom code to the D365 online (cloud) environment, the CrmServiceClient namespace does not have the equivalent class.
So my question is, how can I upgrade the custom code so it will work in the online environment without changing the whole code structure?
Any help to point to the right direction is appreciated.
Please let me know if you have any question.
Thank you.
cdjleeus