K kdbarrett Jul 6, 2005 #1 I have code that dynamically creates checkboxes at runtime. How can I capture events from those checkboxes? Thanks
I have code that dynamically creates checkboxes at runtime. How can I capture events from those checkboxes? Thanks
N Nassos Jul 6, 2005 #2 Hi man, when in your code at rine-time initialize the checkBox initialize the even as well!! and add the box1 in an ArrayList CheckBox box1 = new CheckBox(); box1.CheckedChanged +=new EventHandler(box1_CheckedChanged); CheckBoxArray.Add (box1) also, make the box1_CheckedChanged (object Sender, System.EventArgs e) in this method cast the sender and find the checkBox in the arrayList and what must be done Hope that Helps
Hi man, when in your code at rine-time initialize the checkBox initialize the even as well!! and add the box1 in an ArrayList CheckBox box1 = new CheckBox(); box1.CheckedChanged +=new EventHandler(box1_CheckedChanged); CheckBoxArray.Add (box1) also, make the box1_CheckedChanged (object Sender, System.EventArgs e) in this method cast the sender and find the checkBox in the arrayList and what must be done Hope that Helps
K kdbarrett Jul 8, 2005 #3 I can't seem to get this to work. Can you point me to a more detailed example? Thanks!