我们在Winform应用程序中看到这个错误。这该如何解决呢?具体如下:
System.ComponentModel.Win32Exception:创建窗口句柄时出错。
在System.Windows.Forms.NativeWindow.CreateHandle(CreateParams cp)
在System.Windows.Forms.Control.CreateHandle()
在System.Windows.Forms.Control.CreateControl(布尔fIgnoreVisible)
在System.Windows.Forms.Control.CreateControl()
在System.Windows.Forms.Control.OnVisibleChanged(EventArgs e)
在System.Windows.Forms.ButtonBase.OnVisibleChanged(EventArgs e)
发布于 2018-03-12 17:01:22
你的应用程序的窗口句柄限制为10,000个句柄。你得到的错误是因为你的程序创建了太多的句柄。你需要找到内存泄漏。正如其他用户建议的那样,使用Memory Profiler。
https://stackoverflow.com/questions/-100007593
复制相似问题