C#代码,用于将一种形式链接到其他形式 [英] c# code for link one form to other forms

查看:85
本文介绍了C#代码,用于将一种形式链接到其他形式的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

将一个表单链接到其他表单的c#代码

c# code for link one form to other forms

推荐答案

我不清楚您的问题,但可能是您想要这个问题

假设你想显示form2

Form2 f2 =新的Form2();
f2.Show();
i m not getting ur question clearely but may be u want this

suppose u want to show form2

Form2 f2 = new Form2();
f2.Show();


Amuait.

如果您指的是MDI应用程序,则:

1.在主窗体(父窗体)中将属性"IsMdiContainer"设置为"true".
2.对于您希望在父表单中打开/显示的每个表单:

Hi Amuait.

If you are referring to an MDI application then:

1. Set the property "IsMdiContainer" to "true" in your main form (Parent Form).
2. For each form you wish to open / show within the parent form:

AForm MyChildForm = new AForm();
AForm.MdiParent = MyMainForm;
AForm.Show();



如果以上不是您要查找的内容,能否详细说明您的要求....



If the above is not what you''re looking for, could you explain your requirement in a bit more detail....


这篇关于C#代码,用于将一种形式链接到其他形式的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆