Last post Nov 25, 2008 02:26 PM by Rampidbyter
Nov 25, 2008 12:26 PM|espresso|LINK
we have a server control which spits out an ImageButton like this:
Button btn = new Button();
btn.CssClass = buttonCssClass;
btn.Text = string.IsNullOrEmpty(this.addButtonText) ? DefaultAddButtonText : this.addButtonText;
btn.Click += new EventHandler(addButton_Click);
addButton = btn;
of course we have a bunch of properties we created, but I thought that since we are inheriting from System.Web.UI.Control that you'd automatically get those events to choose from. We get most of them but not these two.
Nov 25, 2008 02:26 PM|Rampidbyter|LINK
Try inheriting from System.Web.UI.WebControls.Button instead of System.Web.UI.Control.