Monthly Archives: July 2015

CRM for Phones: “A primary entity column cannot have a dot in its name”

Published by:

When using the new CRM For Phones and CRM for Tablets apps against Microsoft Dynamics CRM 2015 Online Update 1, I was getting the following error.

“Sorry, something went wrong while initializing the app. Please try again, or restart the app.”

I looked into some of the standard troubleshooting steps for this one and none of them applied.

So I enabled tracing. It was a big PITA to install all 150mb of iTunes and wait for sync, but it was worth it because I found the following error in the logs.

Error Message:Microsoft.Crm.CrmInvalidOperationException: Unable to process the following entities - contact. Please try disabling the entities and try again. ---> Microsoft.Crm.CrmException: A primary entity column cannot have a dot in its name

The key being A primary entity column cannot have a dot in its name.

Because “having a dot in its name” alludes to an aliased field, I checked that my custom code didn’t contain anything odd – it didn’t. I finally found the problem in a corrupt View definition.

2015-07-27 13_36_02-View_ Contacts_ No Orders in Last 6 Months - Microsoft Dynamics CRM - Internet E

2015-07-27 14_44_14-Message from webpage

After removing the bad columns, the mobile app fired up no problem.

ISV code aborted the operation.

Published by:

When writing a Microsoft Dynamics CRM plugin, you might come across the dreaded “ISV code aborted the operation” (isvaborted) error – code -2147220891 or 80040265.

In my experience this means the plugin is calling itself. For example, if your plugin fires on change of estimatedvalue on Opportunity, and your plugin updates estimatedvalue, you’re going to get an infinite loop.

Nip it in the bud with this simple line:

if (context.Depth > 1) {
                trace.Trace("Plugin has called itself. Exiting.");
                return;
            }