在ASP.NET System.Linq的命名空间CS0234错误 [英] CS0234 error with System.Linq namespace in ASP.NET

查看:855
本文介绍了在ASP.NET System.Linq的命名空间CS0234错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在我的公司,我们已经分层环境为我们的web应用程序(开发,运行,生产)。我做了一堆变化对我的应用程序之一,并将其​​部署到开发环境(Windows 2003中瓦特/ IIS 6.0)。我也不得不做出立即改变到需要解决的问题与当前的生产应用程序的用户控制文件中的一个。

At my company, we have tiered environment for our web applications (development, staging, production). I made a bunch of changes to one of my applications and deployed them to the development environment (Windows 2003 w/ IIS 6.0). I also had to make an immediate change to one of the user control files that needs to fix issue with the current production application.

我刚刚部署的一个文件到临时环境(Windows 2003中瓦特/ IIS 6.0),这是生产上得到了下面的ASP.NET 2.0的编译错误的精确拷贝。

I just deployed the one file to the staging environment (Windows 2003 w/ IIS 6.0), which is an exact copy of production on got the following ASP.NET 2.0 compilation error.

异常类型:HttpCompileException
  异常消息:
  D:\\的Inetpub \\ MyApp的\\ BaseControl.cs(3):
  错误CS0234:类型或命名空间
  名'的LINQ'中不存在
  命名空间'系统'(是否缺少一个
  集引用?)

Exception type: HttpCompileException Exception message: d:\inetpub\myapp\BaseControl.cs(3): error CS0234: The type or namespace name 'Linq' does not exist in the namespace 'System' (are you missing an assembly reference?)

我复制从生产原始文件(Windows 2003中瓦特/ IIS 6.0)回落到分期,得到了同样的错误。我还回收并重新启动应用程序池。我仍然得到同样的结果。

I copied the original file from production (Windows 2003 w/ IIS 6.0) back down to staging and got the same error. I also recycled and restarted the application pool. I still get the same result.

有每个人经历过这个问题,并知道如何解决它?

Has everyone experienced this issue and know how to resolve it?

更新:

在.NET 3.5框架已安装在开发和分期服务器上。每个环境托管在同一台服务器上。开发环境是工作得很好。

The .NET 3.5 framework is installed on the development and staging server. Each environment is hosted on the same server. The development environment is working just fine.

推荐答案

我的web.config文件是从我的临时环境缺失。我复制从生产环境中的web.config和一切工作......

My web.config file was missing from my staging environment. I copied the web.config from the production environment and everything is working...

这篇关于在ASP.NET System.Linq的命名空间CS0234错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆