SYMPTOMS
The default value of a record is not populated in Microsoft Dynamics CRM.
CAUSE
The value of a field is not automatically set to its default value when you create a record outside the Microsoft CRM application user interface. For example, you create a record through a platform call using the Create method and do not set the value of a field in the IncidentXML parameter.
RESOLUTION
The XML string that is passed to the create method must contain any custom fields as shown by the following example:
// Set up the XML string for the new case (incident). strIncidentXml = "<incident>"; strIncidentXml += "<title>" + "Case" + "</title>"; strIncidentXml += "<accountid>" + strAccountId + "</accountid>"; strIncidentXml += "<prioritycode>" + "1" + "</prioritycode>"; // Workaround for a custom field. For a boolean, the default value must be set to "0". strIncidentXml += "<CFBCustomField>" + "0" + "</CFBCustomField>"; strIncidentXml += "</incident>";
MORE INFORMATION
When you use the Microsoft Dynamics CRM 3.0 SDK to insert data into any of the system entities or into any of the custom entities, you can save null values. Additionally, the Microsoft CRM 3.0 SDK does not trigger any of the business rules that are defined in the customization tool. This is a known behavior of the Microsoft CRM 3.0 SDK if you use Microsoft BizTalk Server Adapter for Microsoft CRM to load data into the Microsoft CRM database. When Microsoft CRM uploads the data, the business rule validations for the fields are not triggered. This occurs because the BizTalk Server Adapter for Microsoft CRM was built by using the Microsoft CRM SDK. The Microsoft CRM SDK does not trigger business rules that are defined for fields, and the Microsoft CRM SDK does not test for null values. This is a known limitation of the Microsoft CRM SDK.
MORE INFORMATION
You can contact a Microsoft CRM support professional directly at 877-752-1122
For Additional Information, please see:
http://mscrm.exiis.net/microsoft-crm-consulting/Pages/default.aspx