Announcements
Hello Community,
I am getting an error in my Console App which is run for the last 2 years without any issue similar to this "Unable to Login to Dynamics CRMOrganizationServiceProxy is null"
Following is the screenshot for code for connection:
We have just changed the password for that user because the password got expired recently. But in CRM Connection string we have updated the password.
Can you anyone please let me know why we are getting the issue?
I have used the credentials for another environment then it is working. It is not an issue with Codebase or Package used. I think it because of user configuration.
Amit,
So what exactly doesn't work?
Also what "rework on the code" do you mention? There (usually) no need to change the code when you change the reference to the most recent version of assemblies.
Hi,
I have try to change the connection line with your line of code but it didn't work for me:
IOrganizationService service = new CrmServiceClient(ConfigurationManager.ConnectionStrings["CRM"].ConnectionString);
I can't update the packages because the codebase is 3 years old and If I will update the package to the latest version then I need to do rework on the code.
Hello,
I don't have the exact reason why your code stopped working but I know what to do to fix it:
I would recommend to update references to use the latest version of the SDK from NuGet and replace 2 and 3 lines with a single line:
IOrganizationService service = new CrmServiceClient(ConfigurationManager.ConnectionStrings["CRM"].ConnectionString);
André Arnaud de Cal...
294,125
Super User 2025 Season 1
Martin Dráb
232,871
Most Valuable Professional
nmaenpaa
101,158
Moderator