SAP Knowledge Base Article - Public

1556570 - Error: The type or namespace name 'CrystalDecisions' could not be found

Symptom

  • Running a console application project results in the error:

The type or namespace name 'CrystalDecisions' could not be found (are you missing a directive or an assembly reference?)

Environment

  • VS2010
  • CRVS2010

Reproducing the Issue

  • Create a console application in VS2010
  • Add a Crystal Report
  • CrystalDecisions.CrystalReports.Engine, CrystalDecisions.ReportSource and CrystalDecisions.Shared are added automatically
  • Run the application

Cause

  • The target framework was set to .Net Framework 4 Client

Resolution

  • Set target framework to .Net Framework 4 full

Keywords

CR2010 2010 CR4VS2010 CR4VS VS2010 NET2010 , KBA , BI-DEV-NET , BI Software Development Kits (SDKs) - .NET or Other , How To

Product

SAP Crystal Reports, developer version for Microsoft Visual Studio