Jump to content
Xtreme .Net Talk

Recommended Posts

Posted

I would like to know if it ispossible to create something like a user control, but being able to manipulate separatly each control of the user control.

Just explain with an exemple.

Say I want to do a special component composed with a DataGrid and a TextBox. I want to create a component because I want them to have a special behaviour: the textBox will act as a search criteria field for the datagrid.

I would like that in a component to be able to use it in different applications or in different forms.

 

However, I don't want to use a user control because these controls won't have a fixed position (I don't always want the TextBox to be above the datagrid) and being able to move these control at design time.

 

I don't know if I'm clear...

Is there a way to encapsulate code for a "user control" without fixing the relative position of the control?

 

Thanks

Jarod
  • *Gurus*
Posted
Good question - you may have to do things manually, but on the other hand you might get away with just adding the controls to the usercontrol at design time using IDesignerHost.CreateComponent to create them. That way they'll have the designers created for them that they would if they were hosted on a normal design surface.

MVP, Visual Developer - .NET

 

Now you see why evil will always triumph - because good is dumb.

 

My free .NET Windows Forms Controls and Articles

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...