[英]VS2013 Express Error: namespace is not recognized
I have three projects: BLL, DAL and mycv. 我有三个项目:BLL,DAL和mycv。 after to reference DAL inside BLL, BLL inside mycv, I tried to call a funcion installed inside BLL which is existing.
在引用BLL内的DAL,mycv内的BLL之后,我尝试调用已安装在BLL内的funcion。
I am using Visual Studio 2013 Express, MVC5, AngularJS (I added as nuget) and JQuery libraries (I added as nuget). 我正在使用Visual Studio 2013 Express,MVC5,AngularJS(我作为nuget添加)和JQuery库(我作为nuget添加)。
I installed Target Framework as 4.0 version. 我将目标框架安装为4.0版本。
When I use using BLL, the namespace is not recognized. 使用BLL时,无法识别名称空间。
I give you the structure of my solution and you'll see all the references: 我给您解决方案的结构,您将看到所有参考:
DAL code is: DAL代码是:
public class DatosPersonales
{
public Entities.DatosPersonales getDatosPersonales_DAL()
{
return new Entities.DatosPersonales();
}
}
BLL code is: BLL代码为:
public class DatosPersonales
{
public Entities.DatosPersonales getDatosPersonales()
{
return DAL.DatosPersonales();
}
}
Finally, in mycv project I call BLL class of DatosPersonales: 最后,在mycv项目中,我将DatosPersonales的BLL类称为:
public ActionResult Index()
{
var clase = new DatosPersonales();
return View();
}
With that error I can not compile succesfully. 由于该错误,我无法成功编译。
If you need something more to add let me know and I will give you more information. 如果您需要添加更多信息,请告诉我,我会给您更多信息。
What is wrong? 怎么了?
Have you checked that your DAL layer i building successfully. 您是否检查过我的DAL层是否已成功构建。 Try cleaning the layers and build them one by one.
尝试清洁这些层,然后一层一层地构建它们。 First DAL, then BLL and finally the main layer.
首先是DAL,然后是BLL,最后是主层。
Sometimes if your most inner layer (or DAL in your case) doesn't compiles successfully, it affects the other layers as well. 有时,如果最内层(在您的情况下为DAL)无法成功编译,那么也会影响其他层。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.