Friday, October 4, 2013

Visual Studio 2012 - The type or namespace name '' could not be found (are you missing a using directive or an assembly reference?)

In Visual Studio 2012 if you encounter this error when you add a new class to the solution,check to see the build action of the class in the properties of the class.
By default the build action is set to 'content'.Change it to 'compile'.See below





3 comments:

Anonymous said...

Thank you VERY VERY much!!! Struggled with this error for about an hour

Sunrise_a7 said...

Thanks you!

Unknown said...

Tried that and it failed to fix the error,well
Another solution is to make sure your namespace matches with all the namespaces in your source code