Jump to content
Xtreme .Net Talk

Recommended Posts

Posted

In the process of converting a j++ project to C#.

 

In the j++ project we have one form called frmWizard. We have these other forms which copy their controls to frmWizard. This is accomplished by copying the Panel which contains all the controls on the form. Then we use the method in the Panel in frmWizard to copy all the controls onto it.

 

An example of this is.

 

pnlQuestions.setNewControls(new Control[]{frmDialog.pnlPUProdAllocation});

 

The converted code looks something like this.

 

pnlQuestions.Controls.AddRange(new Control[] {frmDialog.pnlPUProdAllocation});

 

My question is......Is there an easier and cleaner way to do this in C#???

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...