【问题标题】:Visual Studio does not show names of loaded assembliesVisual Studio 不显示已加载程序集的名称
【发布时间】:2013-01-07 04:54:36
【问题描述】:

从 Visual Studio 中运行 c# 项目并观察调试输出时,可以看到每个程序集的确切加载时间。 (右键调试输出窗口,勾选“显示模块加载消息”)

根据 StackOverflow 上的屏幕截图和其他问题,我知道每个程序集都应该有一条消息,其中包含该程序集的名称。
然而,在我的电脑上大部分时间我得到的只是无名的加载消息。名字不见了。

当我进入模块窗口时,我可以看到所有加载模块的名称(调试菜单,选择 Windows,然后单击模块。)

如何让名称出现在输出窗口中? 在极少数情况下它似乎有效,但我无法重现这些情况。

这是我可以在调试输出窗口中看到的三种类型的程序集加载消息(对不起,德语)

"MyProgram.vshost.exe" (Verwaltet): "Verwaltet" wurde geladen, das Laden von Symbolen wurde übersprungen. Das Modul ist optimiert, und die Debugoption "Nur eigenen Code" ist aktiviert.
"MyProgram.vshost.exe" (Verwaltet): "Verwaltet" geladen, Symbole geladen.
"MyProgram.vshost.exe" (Verwaltet): "Verwaltet" wurde geladen

这里是英文的粗略翻译

'MyProgram.vshost.exe' (Managed): Loaded 'Managed'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'MyProgram.vshost.exe' (Managed): Loaded 'Managed', loaded symbols.
'MyProgram.vshost.exe' (Managed): Loaded 'Managed'


这是我期望的输出:

'Example.vshost.exe' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_MSIL\IdeaBlade.UI.WinForms.DevExpressControls.v2_2_0\3.6.7.1__287b5094865421c0\IdeaBlade.UI.WinForms.DevExpressControls.v2_2_0.dll'
'Example.vshost.exe' (Managed): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_32\mscorlib\v4.0_4.0.0.0__b77a5c561934e089\mscorlib.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'Example.vshost.exe' (Managed): Loaded 'C:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE\QTAgent32.exe', Symbols loaded.
'Example.vshost.exe' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_32\mscorlib\2.0.0.0__b77a5c561934e089\mscorlib.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'Example.vshost.exe' (Managed): Loaded 'C:\Windows\assembly\GAC_MSIL\Microsoft.VisualStudio.QualityTools.ExecutionCommon\10.0.0.0__b03f5f7f11d50a3a\Microsoft.VisualStudio.QualityTools.ExecutionCommon.dll', Symbols loaded.

以上日志中程序集的路径和名称是我的电脑上缺少的。

(Visual Studio 2008 专业版)

【问题讨论】:

  • Ctrl+W,O 是否显示输出以及输出窗口
  • 我可以看到输出窗口,我可以看到模块加载消息和调试消息。但是模块加载消息缺少模块名称。 ctrl+w,o 聚焦该输出窗口,但不改变内容

标签: c# .net visual-studio visual-studio-2008 assemblies


【解决方案1】:
  1. 您能否检查一下 “模块加载消息” 是否已启用

    您可以在以下位置找到它: 工具 -> 选项 -> 调试 -> 输出窗口 -> 常规输出设置 -> 模块加载消息

  2. 工具 -> 选项 -> 调试 -> 常规 -> 仅启用我的代码(仅限托管)

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2021-05-31
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2011-02-06
    • 1970-01-01
    相关资源
    最近更新 更多