Unable to cast object of type 'System.DBNull' to type 'System.String' occurs when you run the "Synchronize with CRM" function in the Microsoft Dynamics CRM 2011 Outlook Client

Article ID: 2715605 - View products that this article applies to.
Expand all | Collapse all

SYMPTOMS

During synchronization of the Microsoft Dynamics CRM 2011 for Microsoft Office Outlook client, a user will receive the following error: 

"Microsoft CRM has encountered a problem and needs to close. We are sorry for the inconvenience." 

When reviewing the error details within the error dialog box by clicking "What does this error report contain?", the following error will be shown: 

"Unable to cast object of type 'System.DBNull' to type 'System.String'"

CAUSE

The error is caused by a field in a local SQL CE database that contains a null value

RESOLUTION

Use the following steps to resolve this issue on a Windows XP machine:

1. Close Microsoft Office Outlook
2. Browse to C:\Documents and Settings\<Username>\Application Data\Microsoft\MSCRM\Client and delete the contents of this folder, which will include the local SDF files
3. Browse to C:\Documents and Settings\<Username>\Local Settings\Application Data\Microsoft\MSCRM\Client and delete the contents of this folder, which will include the local SDF files
4. Start Microsoft Office Outlook
5. When you start Outlook for the first time after deleting the SDF files, you will notice some slow performance. This is expected because the SDF files are being recreated.

Use the following steps to resolve this issue on a Windows Vista or Windows 7 machine:

1. Close Microsoft Office Outlook
2. Browse to C:\Users\<Username>\AppData\Roaming\Microsoft\MSCRM\Client and delete the contents of this folder, which will include the local SDF files
3. Browse to C:\Users\<Username>\AppData\Local\Microsoft\MSCRM\Client and delete the contents of this folder, which will include the local SDF files
4. Start Microsoft Office Outlook
5. When you start Outlook for the first time after deleting the SDF files, you will notice some slow performance. This is expected because the SDF files are being recreated.
Note This is a "FAST PUBLISH" article created directly from within the Microsoft support organization. The information contained herein is provided as-is in response to emerging issues. As a result of the speed in making it available, the materials may include typographical errors and may be revised at any time without notice. See Terms of Use for other considerations.

Properties

Article ID: 2715605 - Last Review: June 1, 2012 - Revision: 5.0
APPLIES TO
  • Microsoft Dynamics CRM 2011
  • Microsoft CRM client for Microsoft Office Outlook
Keywords: 
kbmbsmigrate kbsurveynew KB2715605

Give Feedback

 

Contact us for more help

Contact us for more help
Connect with Answer Desk for expert help.
Get more support from smallbusiness.support.microsoft.com