Hi All,
I have to create case throgh a stand alone web application. For that i have created a webform to get the data from users. And i created the service
to connect with my CRM. The issue i am facing is in case form as you knows the Customer field is mandatory. How I can set a default customer for the cases created throgh the webform. I tried so many things. But the error massage comes like , " You should specify a parent contact or account." Please help me to solve this issue.
Entity caseent = new Entity("incident");
// Set the required attributes. For account, only the name is required.
// See the Entity Metadata topic in the SDK documentatio to determine
// which attributes must be set for each entity.
Guid contgid = new Guid("8EEDB353-E0B6-E611-80C7-000C29155BE6");
caseent["title"] = title;
ColumnSet newColumnSet=new ColumnSet(new string[]{"fullname","contactid" });
Entity RetrievedEntityById = _service.Retrieve("contact", contgid, newColumnSet);
// caseent.Attributes.Add("customerid", "CF5DB565-C2B6-E611-80C7-000C29155BE6");
// Create an account record named Fourth Coffee.
// caseent["contactid"] = RetrievedEntityById.Attributes["contactid"];
// caseent["customerid"] = RetrievedEntityById.Attributes["contactid"];
// caseent["contactname"] = RetrievedEntityById.Attributes["fullname"];
_accountId = _service.Create(caseent);
thanks