I have a parent user control with a label. On the parent’s OnInit, I dynamically load the child control. From the child control, I will need to set the parent’s label to something.
Using the Parent property returns the immediate parent which is actually a PlaceHolder in my case. Theoretically, I can recursively loop to get the reference to the Parent User control. Am I heading in the right direction here? Is there a straightforward way of doing this?
Try getting the child’s NamingContainer.