I have a usercontrol that is inside another user control, what I would like to do is after a certain process runs to find the button control in the parent and run the OnClick event.
usercontrol 1
protected void btnReload_Click(object sender, EventArgs e)
{
//reloads data
}
usercontrol 2 (embeded in usercontrol 1)
protected void btnSave_Click(object sender, EventArgs e)
{
Button btnReload = (Button)Parent.FindControl("btnReload");
//here fire the btnReload onclick even
}
if this is not the best way I take recomendations cause I'm to the point of pulling my hair out over this. The reason I am doing this is because I have 8 pages that all require to create a new user so I would like to use 1 usercontrol for that but reload the page they are on with that new user created.