c# - 模块窗口中的 dll 符号状态显示 "Skipped Loading"?

标签 c# iis visual-studio-2013 pdb-files

我最近将一些解决方案升级到了 Visual studio 2013。除了一个现在生成的解决方案外,一切正常:

Symbol for the modules 'name' were not loaded.

...每次运行都会出错。

当我查看模块调试窗口时,我可以看到 dll(它是一个 web 服务 dll)

Name           Path                       Optimised    User Code    Symbol Status
dllName.dll    Tempoary ASP.Net...etc.    Yes          No           Skipped Loading...

如果我查看 \bin,我会看到 dll 及其对应的 .pdb 文件。

检查项目的构建菜单,我可以看到 Debug Info: full

长话短说,除了没有加载任何符号外,一切看起来都很好。

知道我错过了什么吗?

更新

看起来如果我通过 IIS Express 运行我的解决方案,问题就会消失。但是通过 IIS (8) 运行我仍然遇到这个问题。

最佳答案

在痛苦地比较了两个项目文件后,一个有效,一个无效,我注意到有效的项目有:

<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
    <DebugSymbols>true</DebugSymbols>
    <DebugType>full</DebugType>
    **<Optimize>false</Optimize>**
    <OutputPath>bin\</OutputPath>
    <DefineConstants>DEBUG;TRACE</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
  </PropertyGroup>

和我的一样

<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
    <DebugSymbols>true</DebugSymbols>
    <DebugType>full</DebugType>
    **<Optimize>true</Optimize>**
    <OutputPath>bin\</OutputPath>
    <DefineConstants>DEBUG;TRACE</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>

  </PropertyGroup>

通过设置 <Optimize>属性(property)false所有问题都消失了。

answer also seems relevant作为 .csproj.user文件可能不同步,我删除了它。

关于c# - 模块窗口中的 dll 符号状态显示 "Skipped Loading"?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/25888343/

相关文章:

c# - asp.net mvc4 中 web.config 中的 Windows 身份验证

c# - 使用 WinSCP .NET 程序集时,...\WinSCP.exe 的版本与该程序集的版本不匹配

c# - Entity Framework 4.1 Code First - 是否应该初始化许多关系 ICollections

c# - 从 HtmlInputRadioButton 接收 RenderedNameAttribute

visual-studio-2013 - 发布时出现 SSDT 错误,但构建时未出现 SSDT 错误

c# - 按用户输入过滤获取错误消息无法获取表 0

tfs - 将 TFS 工作区从 "Server"转换为 "Local"失败并出现错误 "Not a valid Win32 FileTime"

c# - 如何在 MessageContract 类型中使用 XML 属性?

asp.net - IIS 不释放内存

c# - 使用反向代理通过 SSL(https) 配置 IIS 托管的 WCF 服务