Monday, 9 July 2012

The type or namespace name 'Crm' does not exist in the namespace 'Microsoft'

I started working in a new project that uses Microsoft Dynamics CRM 2011 recently and I was trying to compile a console application to quickly test a method but no matter what I did, I kept getting a few of these errors:

The type or namespace name 'Crm' does not exist in the namespace 'Microsoft'
The type or namespace name 'Xrm' does not exist in the namespace 'Microsoft'

This despite the fact that I had added the SDK references to the project and then re-added them for good measure, but to no avail.  Then I remembered (actually, somebody pointed it out) that by default the Target Framework is set to the Client Profile rather than the Full Profile, so I changed it to the Full profile, like this:
  1. On the Project menu, click ProjectName Properties.
  2. Click the Application tab (selected by default).


  3. In the Target framework list, select .NET Framework 4.0.


  4. You'll see this dialog: Press Yes (The project properties will close).




  5. You can now compile your project.

2 comments:

  1. Thanks for putting this up
    This really saved my time :)

    ReplyDelete
  2. Thanks buddy it worked out...

    ReplyDelete