I have 2 user controls: uc1.ascx and uc2.ascx. Both are placed in the same folder. uc1 needs to load uc2, and set a uc2 property. But I cannot figure out how to set the property.
In uc2.ascx, I have the public property with getter and setter.
In uc1.ascx, I do:
UserControl uc2 = (UserControl) LoadControl("uc2.ascx");
uc2.Property = someValue; //error - cannot find Property
panel1.Controls.Add(uc2); //panel1 is a panel in uc1
Am I missing something here? Thanks!
...
Go to the complete details ...