本文介绍了MDIContainer提供错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
当我尝试检查活动表单是否为MDIContainer时,我一直收到空引用错误.对象引用未设置为对象的实例.
这是我尝试的方法:
When I try to do a check to see that the active form is an MDIContainer, I keep getting an null reference error. Object reference not set to an instance of an object.
This is what I try:
if(form.ActiveForm.IsMdiContainer)
有时,即使我将子窗体的MdiParent设置为MDIcontainer,也会在MDI容器外部打开子窗体.
MDIContainer甚至可以很好地使用,还是我应该寻找更好的东西?
Also some times a child form will open outside of the MDI container even though I set the MdiParent of that child form to the MDIcontainer.
Is MDIContainer good to use even or is there something better I should be looking at?
Any help would be greatly appreciated
推荐答案
这篇关于MDIContainer提供错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!