Solved

Creating Copies of a set of controls

Posted on 2006-07-09
4
177 Views
Last Modified: 2010-04-23
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
Comment
Question by:TommyTwoPints
  • 2
  • 2
4 Comments
 
LVL 24

Accepted Solution

by:
Jeff Certain earned 500 total points
ID: 17075448
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
 
LVL 3

Author Comment

by:TommyTwoPints
ID: 17075521
Excellent,

Thanks alot!
0
 
LVL 24

Expert Comment

by:Jeff Certain
ID: 17075672
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
 
LVL 3

Author Comment

by:TommyTwoPints
ID: 17075705
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

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Since .Net 2.0, Visual Basic has made it easy to create a splash screen and set it via the "Splash Screen" drop down in the Project Properties.  A splash screen set in this manner is automatically created, displayed and closed by the framework itsel…
Introduction As chip makers focus on adding processor cores over increasing clock speed, developers need to utilize the features of modern CPUs.  One of the ways we can do this is by implementing parallel algorithms in our software.   One recent…
This video shows how to quickly and easily add an email signature for all users on Exchange 2016. The resulting signature is applied on a server level by Exchange Online. The email signature template has been downloaded from: www.mail-signatures…
Established in 1997, Technology Architects has become one of the most reputable technology solutions companies in the country. TA have been providing businesses with cost effective state-of-the-art solutions and unparalleled service that is designed…

837 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question