Persisting value for children control...

X

XBoy

I am creating a webcontrol custom control using asp .net. I have the parent control and within that control i am adding the children controls using the contents of children tag. The children tag have some of the properties that i am interested in during the roundtrip between browser and server. The problem i am facing is that after the user modifies the properties of these children control on browser/in the code and posts back, the children properties are lost!!!. Here is the pseudo code for what i am trying to do

MyWebCtl webControl,INamingContaine


[DesignerSerializationVisibility(DesignerSerializationVisibility.Content ),PersistenceMode(PersistenceMode.InnerDefaultProperty),NotifyParentProperty(true)
public ItemCollection Items //Property containing the collection of "children control property

override protected void CreateChildControls(){...}

public override ControlCollection Controls{

protected override void Render(HtmlTextWriter output){



[TypeConverter(typeof(ExpandableObjectConverter))
public class childrenTab(){} //This class contains all the properties that i am interested i
Any help is appreciated
Thanks
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,777
Messages
2,569,604
Members
45,227
Latest member
Daniella65

Latest Threads

Top