Warning: file_get_contents(/data/phpspider/zhask/data//catemap/6/entity-framework/4.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C# 如何从CMD(Shell)编译测试类和实体Framework Model.Designer.cs_C#_Entity Framework_Shell_Compiler Errors_Cmd - Fatal编程技术网

C# 如何从CMD(Shell)编译测试类和实体Framework Model.Designer.cs

C# 如何从CMD(Shell)编译测试类和实体Framework Model.Designer.cs,c#,entity-framework,shell,compiler-errors,cmd,C#,Entity Framework,Shell,Compiler Errors,Cmd,我使用C和实体框架4 我正在尝试在Windows中使用CMD Shell中的测试类 因此,我的工作文件夹包含一个Program.cs简单类,用于一些测试和EF Model.edmx 在Shell中,我在我的工作文件夹中工作,我正在使用此代码尝试编译Program.cs和Model.edmx 收到此错误时,请执行以下操作: Model.Designer.cs(11,19): error CS0234: The Type or name 'Objects does not exist in the

我使用C和实体框架4

我正在尝试在Windows中使用CMD Shell中的测试类

因此,我的工作文件夹包含一个Program.cs简单类,用于一些测试和EF Model.edmx

在Shell中,我在我的工作文件夹中工作,我正在使用此代码尝试编译Program.cs和Model.edmx

收到此错误时,请执行以下操作:

Model.Designer.cs(11,19): error CS0234: The Type or name 'Objects does not exist in the namespace 'Syste.Data' (are you missing an assembly reference?)'
我错过了什么? 谢谢你们的帮助

编辑:我在这里找到了一篇有用的文章:


使用MSBuild.exe解决了问题,但在我的问题中,我有兴趣使用csc.exe,我认为您忘记了引用System.Data.Entity.dll

可能您可以尝试以下命令:

csc *.cs /r:System.Data.Entity.dll
csc *.cs /r:System.Data.Entity.dll