Handling checkchanged eveent of dynamically created checkbox

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • coolmandar
    New Member
    • Feb 2009
    • 2

    #1

    Handling checkchanged eveent of dynamically created checkbox

    HI,
    I am creating checkbox at runtime , and want to handle checkchange event when user click on checkbox
    any suggestion appreciated
  • tlhintoq
    Recognized Expert Specialist
    • Mar 2008
    • 3532

    #2
    A little vague.
    What do you need suggestions regarding?

    Create the checkbox
    Create the method to handle it.
    Subscribe the method to the checkbox

    Code:
    Checkbox chkMyCheck = new Checkbox();
    chkMyCheck.CheckChanged += CheckChangedMethod;
    
    CheckChangedMethod(object sender, eventargs e)
    {
       // Do something here
    }

    Comment

    Working...