NAV/CRM Dynamics Connector – Error – Object reference not set to an instance of an object

I got this error today

NAV/CRM Dynamics Connector – Object reference not set to an instance of an object

this was very frustrating because I hadn’t changed anything, literately tried to turn on the connector to make some changes.

I’m not sure what had happened but the connector had got itself into a right mess.  I tried to repair it and it couldn’t write any values to the MSDI database.

It was complaining about the user privileges but the user had admin rights on the machine and the database.

I tried uninstalling and reinstalling but this didn’t work at all because then the service was appearing in the list of services, the database was still dodgy.

In the end to resolve this problem I had to delete the MSDI database in SQL Server management studio.

What I surmise was the problem was the database had for some reason become corrupted and if you don’t delete the database I think it still leaves it there to use, so when I reinstalled the connector it was still using (or trying to) the corrupted database.

I did find a couple of other blog posts which put forward different answers but they seemed like more effort than deleting and starting again (make sure you back up those maps)

but I will paste them below if you need to try them

this one seems quite promising but it didn’t work for me

http://nav-connector.com/?p=88

 

http://community.dynamics.com/product/ax/axtechnical/b/axsupport/archive/2011/05/24/object-reference-not-set-to-an-instance-of-an-object-while-testing-the-settings-or-running-maps-in-the-ax-crm-connector.aspx

 

CRM 2011 – NAV Connector Gotcha’s

I had to use the CRM/NAV connector this week.  I have to admit I have a heavy heart when ever I have to use the CRM/NAV Connector, it is never easy and amazingly frustrating.

The main problem I have with the connector is the complete lack of examples and documentation and when you start using it, it feels like the connector is a black hole.

Things go in and out but you are never really sure what is happening in the middle and usually why things are not working.

I had to Synchronise the Account entity and two custom entities.  The connectors tool for making custom entities available inside the connector mapping tool is very good.

When you get to the NAV side you have to change the integration table and the best instructions I have found on this is this fantastic blog post which steps through what you have to do.

I had one odd problem, even though I chose not to map contacts and removed all mention of contacts on mapping, if a contact was selected on the account primary contact, it would not sync the account.

even though I didn’t want to sync the contact, it still wouldn’t sync.

After mucking around for a few hours I found that you have to set the dynamics integration field on the contact, if you do this when the account will sync.

another NAV connector gotcha is if you are mapping new entities and non standard tables in NAV then you need to make sure you set the Intergration ID value

I had an entity called Project and on the mapping from CRM to NAV you have to set the Integration ID with the Project\ID

if you don’t set this it will map the change for the first time but then any changes will fail because it can’t link to the entity in CRM without the Integration ID being set

Metaphorix Gold ERP Status with Microsoft Dynamics NAV

Metaphorix the company I work for and which you can read more about here on their homepage or you can read their excellent blog here and yes it’s me who keeps this up to date.

After passing a few people at the company passing some sure step exams and already having the relevant NAV exams passed we retained our Gold Partner status for ERP with Microsoft Dynamics NAV, you can read about this in more detail on this blog page

Gold partner status is worth a bit more these days with Microsoft bumping up the number of certified professionals needed, so well done to everyone involved.

 

 

A Interesting blog on Microsoft Dynamics from Metaphorix

[tweetmeme source=”BenHosk” only_single=false]

I thought I would just let people know I have started to write blog entries for my company blog, which I have set up this week.

The blog will be about CRM, NAV on the technical side and with articles about Metaphorix and the people who work for Metaphorix.

It might be worth adding the blog to your RSS feeds because I other wise you might not come across the articles because it’s a new blog the blog posts appear very far down the google search rankings.

It’s quite a challenge to began a blog from scratch again but it is interesting to write about other things other than just CRM.

I will of course keep writing this CRM blog.

You can read the Metaphorix blog by clicking here 

there are two blog posts of interest (currently there is more on the way)

SQL Optimization

and

a blog entry about the new starters at Metaphorix which you can read about here of which I am one.

if you want to learn more about Metaphorix than you can have a look at the website which you can find here or you can have a look at the company and the employees by looking on linkedin here