Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

uncheck all other checkboxes when one is checked

private void all_CheckedChanged(object sender, EventArgs e)
{

    if (!m_all.Focused)
     return ;

    if (m_all.Checked)
    {
        foreach (CheckBox cb in m_attributes)
        {
            cb.Checked = true;
        }
    }
    else
    {
        foreach (CheckBox cb in m_attributes)
        {
            cb.Checked = false;
        }
    }
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #uncheck #checkboxes #checked
ADD COMMENT
Topic
Name
1+7 =