hi
i have f.aspx page and s.ascx page .
I place a button and a textbox in s.ascx and use that in f.aspx page.my main pag is f.aspx.
I want to when i run f.aspx and click to a label in it ,my code can use findconrol to find state of s.ascx's button.but it's not possible
please help me
Loading
Manikavelu VelayuthamPosted Sep 6, 2010, 3:31 AM
AnkurPosted Sep 6, 2010, 2:06 AM
whats not possible you cannot find button in your control..because i tried the same and it worked:
protected void OnClick(object sender, EventArgs e) //function on page
{
Button btn = (Button)MyContol.FindControl("Button1"); //Button1 is in control, NyControl is placed in this aspx page
}
or is it state of the Button that you cant find.. let me know.