1

我说的是最简单的例子——见下文——显然有些东西已经损坏了。这是完整的错误文本:

新发现!!!启动 Visual Studio 2008——多年来一直使用 C++,从这个 test5.cs 构建了一个新的解决方案,你猜怎么着?. . . 当开始调试时——完全相同的错误!!!此外,我用 C++ 构建了几种类型的微型测试程序,包括 CLR 控制台应用程序......这些都通过“开始调试”正常工作......

帮助!


    <small><small>'test5.vshost.exe' (Managed (v2.0.50727)): Loaded
'C:\Windows\assembly\GAC_32\mscorlib\2.0.0.0__b77a5c561934e089\mscorlib.dll'<br>
          'test5.vshost.exe' (Managed (v2.0.50727)): Loaded
'C:\Windows\assembly\GAC_MSIL\Microsoft.VisualStudio.HostingProcess.Utilities\10.0.0.0__b03f5f7f11d50a3a\Microsoft.VisualStudio.HostingProcess.Utilities.dll'<br>
          'test5.vshost.exe' (Managed (v2.0.50727)): Loaded
'C:\Windows\assembly\GAC_MSIL\System.Windows.Forms\2.0.0.0__b77a5c561934e089\System.Windows.Forms.dll'<br>
          'test5.vshost.exe' (Managed (v2.0.50727)): Loaded
'C:\Windows\assembly\GAC_MSIL\System\2.0.0.0__b77a5c561934e089\System.dll'<br>
          'test5.vshost.exe' (Managed (v2.0.50727)): Loaded
'C:\Windows\assembly\GAC_MSIL\System.Drawing\2.0.0.0__b03f5f7f11d50a3a\System.Drawing.dll'<br>
          'test5.vshost.exe' (Managed (v2.0.50727)): Loaded
'C:\Windows\assembly\GAC_MSIL\Microsoft.VisualStudio.HostingProcess.Utilities.Sync\10.0.0.0__b03f5f7f11d50a3a\Microsoft.VisualStudio.HostingProcess.Utilities.Sync.dll'<br>
          'test5.vshost.exe' (Managed (v2.0.50727)): Loaded
'C:\Windows\assembly\GAC_MSIL\Microsoft.VisualStudio.Debugger.Runtime\10.0.0.0__b03f5f7f11d50a3a\Microsoft.VisualStudio.Debugger.Runtime.dll'<br>
          'test5.vshost.exe' (Managed (v2.0.50727)): Loaded
          'C:\projects\test5\test5\test5\bin\Debug\test5.vshost.exe'<br>
          The thread 'vshost.NotifyLoad' (0x3518) has exited with code 0
          (0x0).<br>
          The thread 'vshost.LoadReference' (0x36a8) has exited with
          code 0 (0x0).<br>
          'test5.vshost.exe' (Managed (v2.0.50727)): Loaded
          'C:\projects\test5\test5\test5\bin\Debug\test5.exe', Symbols
          loaded.<br>
          Ignoring managed exception from unknown thread.The program
          '[6748] test5.vshost.exe: Managed (v2.0.50727)' has exited
          with code -2147023895 (0x800703e9).</small></small>

如果我只是运行测试程序 - 没有错误并且它运行正确......

同样重要的是——如果我进入程序文件并在“调试”下选中“启用非托管代码调试”——调试的开始也可以正常工作......没有错误......这种情况下的输出跟踪有在下面的代码示例之后添加...

我相信这个问题也是我将要发布的下一个问题的原因,即在远程调试会话期间,匹配的 .PDB 文件被报告为不匹配.....

这是示例程序——但这并不重要——我尝试过的所有 C# 示例都是这样的.....

在此先感谢,凯文·韦特


using System;


namespace test5
{
    class Program
    {
        static void Main(string[] args)
        {
            int x = 0;

            while (true)
            {

                System.Console.WriteLine("Hello, World! {0} ", x );

                ++x;
            }
        }
    }
}

'test5.exe': Loaded 'C:\projects\test5\test5\test5\bin\Debug\test5.exe', No native symbols in symbol file.
'test5.exe': Loaded 'C:\Windows\System32\ntdll.dll', Cannot find or open the PDB file
'test5.exe': Loaded 'C:\Windows\System32\mscoree.dll', Cannot find or open the PDB file
'test5.exe': Loaded 'C:\Windows\System32\kernel32.dll', Cannot find or open the PDB file
'test5.exe': Loaded 'C:\Windows\System32\advapi32.dll', Cannot find or open the PDB file
'test5.exe': Loaded 'C:\Windows\System32\rpcrt4.dll', Cannot find or open the PDB file
'test5.exe': Loaded 'C:\Windows\Microsoft.NET\Framework\v4.0.30319\mscoreei.dll', Cannot find or open the PDB file
'test5.exe': Loaded 'C:\Windows\System32\shlwapi.dll', Cannot find or open the PDB file
'test5.exe': Loaded 'C:\Windows\System32\gdi32.dll', Cannot find or open the PDB file
'test5.exe': Loaded 'C:\Windows\System32\user32.dll', Cannot find or open the PDB file
'test5.exe': Loaded 'C:\Windows\System32\msvcrt.dll', Cannot find or open the PDB file
'test5.exe': Loaded 'C:\Windows\System32\imm32.dll', Cannot find or open the PDB file
'test5.exe': Loaded 'C:\Windows\System32\msctf.dll', Cannot find or open the PDB file
'test5.exe': Loaded 'C:\Windows\System32\lpk.dll', Cannot find or open the PDB file
'test5.exe': Loaded 'C:\Windows\System32\usp10.dll', Cannot find or open the PDB file
'test5.exe': Loaded 'C:\Program Files\Google\Google Desktop Search\GoogleDesktopNetwork3.dll', Cannot find or open the PDB file
'test5.exe': Loaded 'C:\Windows\System32\ws2_32.dll', Cannot find or open the PDB file
'test5.exe': Loaded 'C:\Windows\System32\nsi.dll', Cannot find or open the PDB file
'test5.exe': Loaded 'C:\Windows\winsxs\x86_microsoft.windows.common-controls_6595b64144ccf1df_6.0.6001.18000_none_5cdbaa5a083979cc\comctl32.dll', Cannot find or open the PDB file
'test5.exe': Unloaded 'C:\Program Files\Google\Google Desktop Search\GoogleDesktopNetwork3.dll'
'test5.exe': Unloaded 'C:\Windows\System32\ws2_32.dll'
'test5.exe': Unloaded 'C:\Windows\System32\nsi.dll'
The thread 'Win32 Thread' (0x1998) has exited with code 0 (0x0).
'test5.exe': Loaded 'C:\Windows\Microsoft.NET\Framework\v2.0.50727\mscorwks.dll', Cannot find or open the PDB file
'test5.exe': Loaded 'C:\Windows\winsxs\x86_microsoft.vc80.crt_1fc8b3b9a1e18e3b_8.0.50727.6195_none_d09154e044272b9a\msvcr80.dll', Cannot find or open the PDB file
'test5.exe': Loaded 'C:\Windows\System32\shell32.dll', Cannot find or open the PDB file
'test5.exe': Loaded 'C:\Windows\System32\ole32.dll', Cannot find or open the PDB file
'test5.exe': Loaded 'C:\Windows\Microsoft.NET\Framework\v2.0.50727\Culture.dll', Cannot find or open the PDB file
'test5.exe': Unloaded 'C:\Windows\Microsoft.NET\Framework\v2.0.50727\Culture.dll'
'test5.exe': Loaded 'C:\Windows\assembly\NativeImages_v2.0.50727_32\mscorlib\c068708e16abf0be77a21b9f29817d83\mscorlib.ni.dll', Cannot find or open the PDB file
'test5.exe' (Managed (v2.0.50727)): Loaded 'C:\Windows\assembly\GAC_32\mscorlib\2.0.0.0__b77a5c561934e089\mscorlib.dll'
'test5.exe' (Managed (v2.0.50727)): Loaded 'C:\projects\test5\test5\test5\bin\Debug\test5.exe', Symbols loaded.
'test5.exe': Loaded 'C:\Windows\Microsoft.NET\Framework\v2.0.50727\mscorjit.dll', Cannot find or open the PDB file
4

0 回答 0