A
accyboy1981
Hi,
I have created a method that creates a link button dynamically and
places it within a place holder. The code I have creates the button,
but when it is clicked the button method is not fired. Below is the
code the creates the button:
LinkButton lb1 = new LinkButton();
lb1.ID = "lb1" + day.ToString( "ddMMMyyyy" );
lb1.Text = day.ToString( "dd" );
lb1.SkinID = "linkButtonSkin3";
lb1.CommandArgument = day.ToString( "ddMMMyyyy" );
lb1.Click += new EventHandler( EditDay );
A unique ID is given for every button.
I am unsing Visual Studio 2005 and Asp.net 2.0.
Any help on this would be much appreciated.
Thanks in advance.
Simon
I have created a method that creates a link button dynamically and
places it within a place holder. The code I have creates the button,
but when it is clicked the button method is not fired. Below is the
code the creates the button:
LinkButton lb1 = new LinkButton();
lb1.ID = "lb1" + day.ToString( "ddMMMyyyy" );
lb1.Text = day.ToString( "dd" );
lb1.SkinID = "linkButtonSkin3";
lb1.CommandArgument = day.ToString( "ddMMMyyyy" );
lb1.Click += new EventHandler( EditDay );
A unique ID is given for every button.
I am unsing Visual Studio 2005 and Asp.net 2.0.
Any help on this would be much appreciated.
Thanks in advance.
Simon