'Excel.exe' 的调试信息找不到或不匹配

Debugging information for 'Excel.exe' cannot be found or does not match

我正在使用 Visual Studio 2013 编写一个 C++ DLL,然后 EXCEL 意味着通过 VBA 加载 DLL。在 Visual Studio Project Property -> Configuration Properties -> Debugging -> Command = C:\Program Files (x86)\Microsoft Office\Office14\EXCEL.EXE 中设置后,我开始调试,然后出现对话框:

Debugging information for 'Excel.exe' cannot be found or does not matach. Cannot find or open the PDB file. Do you want to continue debugging?

单击“是”后,我注意到 VS 正在尝试下载大量 pdb 文件但失败了:

'EXCEL.EXE' (Win32): Loaded 'C:\Program Files (x86)\Microsoft Office\Office14\EXCEL.EXE'. Cannot find or open the PDB file.

'EXCEL.EXE' (Win32): Loaded 'C:\Windows\SysWOW64\ntdll.dll'. Cannot find or open the PDB file.

'EXCEL.EXE' (Win32): Loaded 'C:\Windows\SysWOW64\kernel32.dll'. Cannot find or open the PDB file.

'EXCEL.EXE' (Win32): Loaded 'C:\Windows\SysWOW64\KernelBase.dll'. Cannot find or open the PDB file.

'EXCEL.EXE' (Win32): Loaded 'C:\Windows\SysWOW64\advapi32.dll'. Cannot find or open the PDB file.

'EXCEL.EXE' (Win32): Loaded 'C:\Windows\SysWOW64\msvcrt.dll'. Cannot find or open the PDB file.

'EXCEL.EXE' (Win32): Loaded 'C:\Windows\SysWOW64\sechost.dll'. Cannot find or open the PDB file.

'EXCEL.EXE' (Win32): Loaded 'C:\Windows\SysWOW64\rpcrt4.dll'. Cannot find or open the PDB file.

'EXCEL.EXE' (Win32): Loaded 'C:\Windows\SysWOW64\sspicli.dll'. Cannot find or open the PDB file.

'EXCEL.EXE' (Win32): Loaded 'C:\Windows\SysWOW64\cryptbase.dll'. Cannot find or open the PDB file.

等等等等,终于调试好了。

这样的VS行为可以吗?我只是觉得有点奇怪,要调试我的 DLL,需要下载 EXCEL.EXE 和 NTDLL.DLL.

的 PDB 文件

这里似乎有一个类似的 post:。但是那个是MVC项目(我的是C++),Visual Studio设置不一样。

Cannot find or open the PDB file.

一般这个错误与加载的符号有关。我们需要在T​​OOLS->Option->Debugging->Symbols下启用symbol Server,检查模块window确保所有symbol都加载成功