C#中编写界面是编译通过,非debug运行正常,但是在调试时运行至ResumeLayout(false)出现错误:
A first chance exception of type 'System.ArgumentException' occurred in System.Windows.Forms.dll
Additional information: Source object does not expose 'IPropertyNotifySink' event interface.
在源代码中使用SuspendLayout(),ResumeLayout(false)没有发现什么错误。
备注一下,我是用的VS2008
A first chance exception of type 'System.ArgumentException' occurred in System.Windows.Forms.dll
Additional information: Source object does not expose 'IPropertyNotifySink' event interface.
在源代码中使用SuspendLayout(),ResumeLayout(false)没有发现什么错误。
备注一下,我是用的VS2008
解决方案 »
- 多线程讨论,并发与优先级问题
- c#如何让实现搜索本地磁盘文件
- 请问我这个登录窗口为啥执行不了?
- 设置上下文菜单出现的问题?(代码如下)
- [请问]如何使窗体获得焦点?——困扰了好久了,微软中文新闻组都没有,高手帮帮忙阿!
- DataGrid焦点如何转移,请大侠帮个解答下。
- 解决.net和水晶报表打包的极佳工具:InstallShield Developer v8.02 免费版 [五星]
- 使用回调函数时,遇到内存不能为写的错误,高手帮忙啊。
- 又要求思归兄帮忙了?怎样实现与.NET里面工具箱里控件可以上下移动的功能呢?
- Software Engineer: Another way to go to USA(job)
- 百分提问,DLL引用失败
- vs2008部署.net framework3.5,复制过程时间超长
应该是某个类库有问题。
http://www.devnewsgroups.net/group/microsoft.public.dotnet.framework.windowsforms/topic52398.aspx
http://www.datadynamics.com/forums/115262/PrintPost.aspx
将多个控件添加到父控件时,建议在初始化要添加的控件之前调用 SuspendLayout 方法。将控件添加到父控件之后,调用 ResumeLayout 方法。这样就可以提高带有许多控件的应用程序的性能。
外行 全当参考