Sto creando un ImageButton dinamicamente in questo modo:
ma l'evento ib_click non mi viene catturato.codice:protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { ImageButton ib = new ImageButton(); ib.ID = "IBIDLJKK"; ib.ImageUrl = "../../App_Themes/White/Images/button-delete.gif"; ib.CommandName = "ib_Command"; ib.Click +=new ImageClickEventHandler(ib_Click); Control c = FindControl("form1"); c.Controls.Add(ib); } }
Qualche aiuto?
Thanks