Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public void SaveAccount(ParentModel objAccountModel)
- {
- using (OrganizationService service = new OrganizationService("MyConnectionString"))
- {
- Guid? accountid = null;
- if (objAccountModel != null)
- {
- Entity accEntity = new Entity("account");
- accEntity["name"] = objAccountModel.Customer.Company;
- accountid = service.Create(accEntity);
- }
- }
- }
- <add name="MyConnectionString" connectionString="Url=https://makeademo.crm.dynamics.com; Username=asin@makeademo.onmicrosoft.com; Password=aaaaa;" />
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement