Answers for "Set value into lookup field in console app using dynamic CRM 365"

C#
1

Set value into lookup field in console app using dynamic CRM 365

Entity recordToUpdate = service.Retrieve("contact", contactId, new ColumnSet(true));
recordToUpdate["parentcustomerid"] = new EntityReference("account", accountId);
service.Update(recordToUpdate);
Posted by: Guest on March-22-2021
0

Set value into lookup field in console app using dynamic CRM 365

Account acc = new Account();
acc.Attributes["name"] = "Ram"; // this values got inserted
acc.Attributes["age"] = "22"; // this values got inserted
acc.Attributes["lookupfieldid"] = new EntityReference("contact", contactId); // if lookupfieldid is pointing to contact entityservice.Create(acc); // to create account
Posted by: Guest on September-14-2021

Code answers related to "Set value into lookup field in console app using dynamic CRM 365"

C# Answers by Framework

Browse Popular Code Answers by Language