I just added a class library project to my new solution and am only given the option of the new class library type. I created my domain classes, which use EF data annotations from System.Component.DataAnnotations. The classes themselves have no errors but the project wont build. I get these errors.
Severity Code Description Project File Line Error CS0234 The type or namespace name 'DataAnnotations' does not exist in the namespace 'System.ComponentModel' (are you missing an assembly reference?) TraderToolkit2016.DomainClasses..NET Platform 5.4 C:\Users\Thomas Donino\Documents\GitHubVisualStudio\TraderToolkit2016\TraderToolkit2016.DomainClasses\AppClasses\DailyClose.cs
I have the assembly referenced. Why am I getting these errors?
Here is my project.json file, DataAnnotations added automatically from VS right click.
{
"version": "1.0.0-*",
"description": "TraderToolkit2016.DomainClasses Class Library",
"authors": [ "Thino" ],
"tags": [ "" ],
"projectUrl": "",
"licenseUrl": "",
"frameworks": {
"net451": {
"frameworkAssemblies": {
"System.ComponentModel.DataAnnotations": "4.0.0.0"
}
},
"dotnet5.4": {
"dependencies": {
"Microsoft.CSharp": "4.0.1-beta-23516",
"System.Collections": "4.0.11-beta-23516",
"System.Linq": "4.0.1-beta-23516",
"System.Runtime": "4.0.21-beta-23516",
"System.Threading": "4.0.11-beta-23516"
}
}
}
}