MIcrosoft .NET Framework应用程序中发生了无法处理的异常。如果单击继续?

打开软件,就出现这个,别人的电脑就不会,怎么回事呢?电脑系统都重装过了,就是不知道哪里没设置对

你看看Form1_Load方法里面给下拉框设置的值是从那里来的,是因为下拉列表没有选项报错。

详细信息

有关调用实时(JIT)调试而不是此对话框的详细信息,
请参见此消息的结尾。

************** 异常文本 **************
System.ArgumentOutOfRangeException: InvalidArgument=“0”的值对于“SelectedIndex”无效。
参数名: SelectedIndex
   在 System.Windows.Forms.ComboBox.set_SelectedIndex(Int32 value)
   在 Toomeen.Form1.Form1_Load(Object sender, EventArgs e) 位置 D:\RichardB\B\PAYG\Ver2\HDE2020\Form1.vb:行号 173
   在 System.Windows.Forms.Form.OnLoad(EventArgs e)
   在 System.Windows.Forms.Form.OnCreateControl()
   在 System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
   在 System.Windows.Forms.Control.CreateControl()
   在 System.Windows.Forms.Control.WmShowWindow(Message& m)
   在 System.Windows.Forms.Control.WndProc(Message& m)
   在 System.Windows.Forms.ScrollableControl.WndProc(Message& m)
   在 System.Windows.Forms.ContainerControl.WndProc(Message& m)
   在 System.Windows.Forms.Form.WmShowWindow(Message& m)
   在 System.Windows.Forms.Form.WndProc(Message& m)
   在 System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   在 System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   在 System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)


************** 已加载的程序集 **************
mscorlib
    程序集版本: 2.0.0.0
    Win32 版本: 2.0.50727.9151 (WinRelRS6.050727-9100)
    基本代码: file:///C:/Windows/Microsoft.NET/Framework/v2.0.50727/mscorlib.dll
----------------------------------------
Toomeen
    程序集版本: 3.0.5.5
    Win32 版本: 3.0.5.5
    基本代码: file:///D:/wang/Toomeen_0330/x86/Debug/Toomeen.exe
----------------------------------------
Microsoft.VisualBasic
    程序集版本: 8.0.0.0
    Win32 版本: 8.0.50727.9136 (WinRelRS6.050727-9100)
    基本代码: file:///C:/Windows/assembly/GAC_MSIL/Microsoft.VisualBasic/8.0.0.0__b03f5f7f11d50a3a/Microsoft.VisualBasic.dll
----------------------------------------
System.Windows.Forms
    程序集版本: 2.0.0.0
    Win32 版本: 2.0.50727.9136 (WinRelRS6.050727-9100)
    基本代码: file:///C:/Windows/assembly/GAC_MSIL/System.Windows.Forms/2.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
----------------------------------------
System
    程序集版本: 2.0.0.0
    Win32 版本: 2.0.50727.9147 (WinRelRS6.050727-9100)
    基本代码: file:///C:/Windows/assembly/GAC_MSIL/System/2.0.0.0__b77a5c561934e089/System.dll
----------------------------------------
System.Drawing
    程序集版本: 2.0.0.0
    Win32 版本: 2.0.50727.9136 (WinRelRS6.050727-9100)
    基本代码: file:///C:/Windows/assembly/GAC_MSIL/System.Drawing/2.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
----------------------------------------
Accessibility
    程序集版本: 2.0.0.0
    Win32 版本: 2.0.50727.9136 (WinRelRS6.050727-9100)
    基本代码: file:///C:/Windows/assembly/GAC_MSIL/Accessibility/2.0.0.0__b03f5f7f11d50a3a/Accessibility.dll
----------------------------------------
System.Runtime.Remoting
    程序集版本: 2.0.0.0
    Win32 版本: 2.0.50727.9136 (WinRelRS6.050727-9100)
    基本代码: file:///C:/Windows/assembly/GAC_MSIL/System.Runtime.Remoting/2.0.0.0__b77a5c561934e089/System.Runtime.Remoting.dll
----------------------------------------
System.Data
    程序集版本: 2.0.0.0
    Win32 版本: 2.0.50727.9156 (WinRelRS6.050727-9100)
    基本代码: file:///C:/Windows/assembly/GAC_32/System.Data/2.0.0.0__b77a5c561934e089/System.Data.dll
----------------------------------------
System.Xml
    程序集版本: 2.0.0.0
    Win32 版本: 2.0.50727.9136 (WinRelRS6.050727-9100)
    基本代码: file:///C:/Windows/assembly/GAC_MSIL/System.Xml/2.0.0.0__b77a5c561934e089/System.Xml.dll
----------------------------------------
System.Configuration
    程序集版本: 2.0.0.0
    Win32 版本: 2.0.50727.9153 (WinRelRS6.050727-9100)
    基本代码: file:///C:/Windows/assembly/GAC_MSIL/System.Configuration/2.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
----------------------------------------
System.Transactions
    程序集版本: 2.0.0.0
    Win32 版本: 2.0.50727.9136 (WinRelRS6.050727-9100)
    基本代码: file:///C:/Windows/assembly/GAC_32/System.Transactions/2.0.0.0__b77a5c561934e089/System.Transactions.dll
----------------------------------------
System.EnterpriseServices
    程序集版本: 2.0.0.0
    Win32 版本: 2.0.50727.9136 (WinRelRS6.050727-9100)
    基本代码: file:///C:/Windows/assembly/GAC_32/System.EnterpriseServices/2.0.0.0__b03f5f7f11d50a3a/System.EnterpriseServices.dll
----------------------------------------
System.Data.resources
    程序集版本: 2.0.0.0
    Win32 版本: 2.0.50727.9136 (WinRelRS6.050727-9100)
    基本代码: file:///C:/Windows/assembly/GAC_MSIL/System.Data.resources/2.0.0.0_zh-CHS_b77a5c561934e089/System.Data.resources.dll
----------------------------------------
System.Windows.Forms.resources
    程序集版本: 2.0.0.0
    Win32 版本: 2.0.50727.9136 (WinRelRS6.050727-9100)
    基本代码: file:///C:/Windows/assembly/GAC_MSIL/System.Windows.Forms.resources/2.0.0.0_zh-CHS_b77a5c561934e089/System.Windows.Forms.resources.dll
----------------------------------------
mscorlib.resources
    程序集版本: 2.0.0.0
    Win32 版本: 2.0.50727.9151 (WinRelRS6.050727-9100)
    基本代码: file:///C:/Windows/Microsoft.NET/Framework/v2.0.50727/mscorlib.dll
----------------------------------------

************** JIT 调试 **************
要启用实时(JIT)调试,
该应用程序或计算机的 .config 文件(machine.config)的 system.windows.forms 节中必须设置
jitDebugging 值。
编译应用程序时还必须启用
调试。

例如: 

<configuration>
    <system.windows.forms jitDebugging="true" />
</configuration>

启用 JIT 调试后,任何无法处理的异常
都将被发送到在此计算机上注册的 JIT 调试器,
而不是由此对话框处理。


 

您好,我是有问必答小助手,您的问题已经有小伙伴解答了,您看下是否解决,可以追评进行沟通哦~

如果有您比较满意的答案 / 帮您提供解决思路的答案,可以点击【采纳】按钮,给回答的小伙伴一些鼓励哦~~

ps:问答VIP仅需29元,即可享受5次/月 有问必答服务,了解详情>>>https://vip.csdn.net/askvip?utm_source=1146287632