我有VS2003 ASP.NET Web应用程序,当我在调试模式下执行生成/重新生成解决方案时,它可以完美地编译和生成,没有错误。
但是,当我将模式更改为“释放”并尝试执行生成解决方案或重新生成解决方案时,对于我所引用的各种DLL,我将收到以下编译错误信息。
我已经用通用XYZ替换了名称空间的名称
找不到类型或命名空间名称“xyz”(是否缺少using指令或程序集引用?)
我所有的引用都是正确的,并且我可以在调试模式下编译而不出现任何错误。
我的操作系统是Windows Vista
有人知道我为什么会在发布模式下得到这个错误以及解决这个问题的可能方法吗?
下面是输出窗口中的示例
我更改了文件名,没有更改实际错误
------ Rebuild All started: Project: XYZ, Configuration: Release .NET ------
Preparing resources...
Updating references...
Performing main compilation...
C:\xyz\a.cs(4,7): error CS0246: The type or namespace name 'ToolLib' could not be found (are you missing a using directive or an assembly reference?)
C:\xyz\a.cs(5,7): error CS0246: The type or namespace name 'ToolLib' could not be found (are you missing a using directive or an assembly reference?)
C:\xyz\a.cs(4,7): error CS0246: The type or namespace name 'ToolLib' could not be found (are you missing a using directive or an assembly reference?)
C:\xyz\a.cs(5,7): error CS0246: The type or namespace name 'ToolLib' could not be found (are you missing a using directive or an assembly reference?)
C:\xyz\a.cs(4,7): error CS0246: The type or namespace name 'ToolLib' could not be found (are you missing a using directive or an assembly reference?)
C:\xyz\a.cs(4,7): error CS0246: The type or namespace name 'ToolLib' could not be found (are you missing a using directive or an assembly reference?)
c:\xyz\b.cs(4,7): error CS0246: error CS0246: The type or namespace name 'Globals' could not be found (are you missing a using directive or an assembly reference?)
c:\xyz\c.cs(5,7): error CS0246: The type or namespace name 'ToolLib' could not be found (are you missing a using directive or an assembly reference?)
c:\xyz\d.cs(4,7): error CS0246: The type or namespace name 'Logger' could not be found (are you missing a using directive or an assembly reference?)
..........
and so on
----------
Build complete -- 26 errors, 0 warnings
Building satellite assemblies...
Satellite assemblies could not be built because the main project output is missing.