Quantcast
Channel: Microsoft Dynamics CRM Forum - Recent Threads
Viewing all articles
Browse latest Browse all 46379

update and create using plugin

$
0
0

when updating my account entity i need a value to be updated in the current account record and create a new record in contact using ,registration mesg in plugin is update -account.(post-syn)

try
{ entity.Attributes["fax"] = "123";//updating my account field during the post-syn

Entity cont = new Entity("contact");

cont.Attributes["parentcustomerid"] = new EntityReference("account", entity.Id);//assigning the current acc id as lookup
cont.Attributes["lastname"] = "test from pl";
service.Create(cont);//creating new contact record 
}//my target entity is "account" 

so is it possible to update and create from an existing record.?


Viewing all articles
Browse latest Browse all 46379

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>