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 

解决方案 »

  1.   


    应该是某个类库有问题。
    http://www.devnewsgroups.net/group/microsoft.public.dotnet.framework.windowsforms/topic52398.aspx
    http://www.datadynamics.com/forums/115262/PrintPost.aspx
      

  2.   

    IPropertyNotifySink是用来实现控件的属性变化通知的接收器,可能有问题。
      

  3.   

    SuspendLayout 调用必须等于零,然后才能成功调用 ResumeLayout。PS:
    将多个控件添加到父控件时,建议在初始化要添加的控件之前调用 SuspendLayout 方法。将控件添加到父控件之后,调用 ResumeLayout 方法。这样就可以提高带有许多控件的应用程序的性能。
     
      

  4.   

    IPropertyNotifySink  问题在这吧
    外行 全当参考