1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
|
public partial class CtrlManifDetail : System.Web.UI.UserControl
{
LinkButton lb;
protected override void CreateChildControls()
{
base.CreateChildControls();
ScriptManager sm = ScriptManager.GetCurrent(Page);
//Ajout de mon bouton
lb = new LinkButton();
lb.ID = "lbTest";
lb.Text = "Bouton de test";
lb.Click += new EventHandler(lbTest_save);
this.Controls.Add(lb);
}
protected void Page_Load(object sender, EventArgs e)
{
}
protected void lbTest_save(object sender, EventArgs e)
{
//Mon traitement
} |
Partager