繁体   English   中英

Visual Studio 2008 - 程序立即退出F5(开始调试)

[英]Visual Studio 2008 - Program exits immediately with F5 (start debugging)

我在Visual Studio中遇到一个奇怪的问题,如果我开始调试它会立即退出。 在项目属性中更改程序集名称后,这种情况就开始发生了。 如果我将程序集名称更改回以前的名称,则程序运行正常。 我怎样才能解决这个问题?

以下是更改程序集名称后运行时的输出:

'SerialDeviceMaintenanceUtility.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.
'SerialDeviceMaintenanceUtility.vshost.exe' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_MSIL\Microsoft.VisualStudio.HostingProcess.Utilities\9.0.0.0__b03f5f7f11d50a3a\Microsoft.VisualStudio.HostingProcess.Utilities.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'SerialDeviceMaintenanceUtility.vshost.exe' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_MSIL\System.Windows.Forms\2.0.0.0__b77a5c561934e089\System.Windows.Forms.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'SerialDeviceMaintenanceUtility.vshost.exe' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_MSIL\System\2.0.0.0__b77a5c561934e089\System.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'SerialDeviceMaintenanceUtility.vshost.exe' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_MSIL\System.Drawing\2.0.0.0__b03f5f7f11d50a3a\System.Drawing.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'SerialDeviceMaintenanceUtility.vshost.exe' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_MSIL\Microsoft.VisualStudio.HostingProcess.Utilities.Sync\9.0.0.0__b03f5f7f11d50a3a\Microsoft.VisualStudio.HostingProcess.Utilities.Sync.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'SerialDeviceMaintenanceUtility.vshost.exe' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_MSIL\Microsoft.VisualStudio.Debugger.Runtime\9.0.0.0__b03f5f7f11d50a3a\Microsoft.VisualStudio.Debugger.Runtime.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'SerialDeviceMaintenanceUtility.vshost.exe' (Managed): Loaded 'C:\DEV\SerialDeviceMaintenanceUtility\SerialDeviceMaintenanceUtility\bin\Release\SerialDeviceMaintenanceUtility.vshost.exe', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'SerialDeviceMaintenanceUtility.vshost.exe' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_MSIL\System.Core\3.5.0.0__b77a5c561934e089\System.Core.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'SerialDeviceMaintenanceUtility.vshost.exe' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_MSIL\System.Xml.Linq\3.5.0.0__b77a5c561934e089\System.Xml.Linq.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'SerialDeviceMaintenanceUtility.vshost.exe' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_MSIL\System.Data.DataSetExtensions\3.5.0.0__b77a5c561934e089\System.Data.DataSetExtensions.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'SerialDeviceMaintenanceUtility.vshost.exe' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_32\System.Data\2.0.0.0__b77a5c561934e089\System.Data.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'SerialDeviceMaintenanceUtility.vshost.exe' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_MSIL\System.Xml\2.0.0.0__b77a5c561934e089\System.Xml.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'SerialDeviceMaintenanceUtility.vshost.exe' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_MSIL\WindowsBase\3.0.0.0__31bf3856ad364e35\WindowsBase.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'SerialDeviceMaintenanceUtility.vshost.exe' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_32\PresentationCore\3.0.0.0__31bf3856ad364e35\PresentationCore.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'SerialDeviceMaintenanceUtility.vshost.exe' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_MSIL\PresentationFramework\3.0.0.0__31bf3856ad364e35\PresentationFramework.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'SerialDeviceMaintenanceUtility.vshost.exe' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_MSIL\WindowsFormsIntegration\3.0.0.0__31bf3856ad364e35\WindowsFormsIntegration.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
The thread 0xd80 has exited with code 0 (0x0).
The thread 0x174 has exited with code 0 (0x0).
'SerialDeviceMaintenanceUtility.vshost.exe' (Managed): Loaded 'C:\DEV\SerialDeviceMaintenanceUtility\SerialDeviceMaintenanceUtility\bin\Release\SerialDeviceMaintenanceUtility.exe', Symbols loaded.
The program '[1632] SerialDeviceMaintenanceUtility.vshost.exe: Managed' has exited with code -1073741819 (0xc0000005).

注意:上面的路径名称已缩写为隐藏组织特定的命名。

我会在程序集名称更改(清理和构建)后重建您的解决方案。

几个月来,我一直在努力禁用VS2008的“turbo-exit”功能。 它似乎与我项目中的XML文件有关。 我把它固定在一个点上,但后来我从IT机器上得到了一台新机器,问题又被引入了。

查看Microsoft KB957912。

您是否尝试在应用程序设置中设置启动对象?

另外,您是否尝试在最早的可用位置设置断点(在WPF应用程序中,这将是您的App.xaml.cs)? 有时你只是没有意识到像InitializeComponent()这样的东西失败了......

最后但同样重要的是,您是否将Reflection与旧的程序集名称(作为字符串)结合使用? 尝试在项目中搜索任何内容

我只是猜测,只有你提供的信息很少,这很难说:(

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM