Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 184
  • Last Modified:

Creating Copies of a set of controls

Hi Experts,

I have a panel containing a set of controls which i would like to replicate at runtime.

How could i declare the panel as a type so i could quite easily create a new copy of it?

Cheers,

Tom

0
TommyTwoPints
Asked:
TommyTwoPints
  • 2
  • 2
1 Solution
 
Jeff CertainCommented:
Simply create a user control and put all the functionality there.

Then, instead of instantianting the panel and all the associated controls, you simply instantiate the user control.
0
 
TommyTwoPintsAuthor Commented:
Excellent,

Thanks alot!
0
 
Jeff CertainCommented:
Glad to help.

Just a word... you want to include only the controls, and not the panel, in the user control. You can still drop this set of controls in a panel for layout purposes, if required.

0
 
TommyTwoPintsAuthor Commented:
Great; I will be using the panel for the title bar.
This particular set for controls is a project template for my application.
Good to know though.

Thanks again,

Tom
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now