Error!
Success!

Find any control on the calling page from within a custom user control

0
kicks

Find any control on the calling page from within a custom user control  (Unpublished)

For when you need to access a control from within a user control where the ID of said control is passed in as a parameter. That was a mouthful. Basically, if you create a custom user control that takes in the ID of another control (let's say a TextBox) the user control cannot find a handle to that control using the standard Page.FindControl("TextBox1"). If TextBox1 exists on the main page (whether or not it's on a master page) and your custom control needs to access TextBox1, it cannot be accessed thru the Page.FindControl method directly. Luckily, there is recursion.


Kicked By:
Drop Kicked By: