且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

克隆 Winform 控件

更新时间:2023-10-19 22:20:10

你可以做的是基于你的 groupbox 创建一个用户控件,它允许它重用.然后,您可以在运行时创建所需的实例并将它们添加到表单中.

What you could do is create a user control based upon your groupbox which would allow its reuse. You could then create the instances you require at runtime and add them to the form.

也许建议您考虑为 winforms 创建用户控件.

Maybe suggest that you look into creating user controls for winforms.