protected void btnSave_Click(Object Sender, EventArgs e) { oWorkstation.DeleteComponentPermission(intComponent); foreach (TreeNode oNode in oTree.Nodes) { if (oNode.Checked == true) { oWorkstation.AddComponentPermission(intComponent, Int32.Parse(oNode.Value)); } } Reload(); }