S
Shawn
Hi All;
I am attempting to figure out how to add a user created control (test.ascx) to an ASP.NET page based on a user choice. I have created a simple page that uses session to keep track of the instantiated class. i have added to the class a simple public property (action) initially set to zero. i also have a panel on the page where the control will apear. i use this code to add the control to the panel.
Panel1.Controls.Add(myTest);
when a certain condition is raised the Action property is changed and when the page is posted back a check on that property shoud make the control appear. however when i run the code and the condition is met the control never appears. i know that the action property is being updated because i am outputing it to the page. any ideas what i could be doing wrong?
Thanks for any help.
I am attempting to figure out how to add a user created control (test.ascx) to an ASP.NET page based on a user choice. I have created a simple page that uses session to keep track of the instantiated class. i have added to the class a simple public property (action) initially set to zero. i also have a panel on the page where the control will apear. i use this code to add the control to the panel.
Panel1.Controls.Add(myTest);
when a certain condition is raised the Action property is changed and when the page is posted back a check on that property shoud make the control appear. however when i run the code and the condition is met the control never appears. i know that the action property is being updated because i am outputing it to the page. any ideas what i could be doing wrong?
Thanks for any help.