i have one check list box which have check box's like admin,physisian,Nurs<practicenerNurse,frontdesk etc
and there is one another check box called "Clinical access"
i want to check any of chechbox in my check list box accept Admin then clinical access check box checked automaticaly have write folowing code but it also check for admin
private void Modules_ItemCheck(object sender, ItemCheckEventArgs e)
{
if (e.NewValue == CheckState.Checked)
{
ClinicalAccess.Checked = true;
ClinicalAccess.Enabled = false;
}
else
{
int i = Convert.ToInt32(Modules.CheckedItems.Count);
if (i > 1)
{
ClinicalAccess.Checked = true;
ClinicalAccess.Enabled = false;
}
else
{
ClinicalAccess.Checked = false;
ClinicalAccess.Enabled = true;
}
}
}
i am working on Windows application with C#