private void newcontactbttn_Click(object sender, EventArgs e) { switch (groupsBindingSource.Count) { default: DazzleDesign_Contact_Reader.Reader Reader = new DazzleDesign_Contact_Reader.Reader(Mode.Mode.EditModeEnum.AddNew, "", ""); if (Reader.ShowDialog() == DialogResult.OK) { ReadData(); } break; case 0: if (MessageBox.Show("You must first create a group before adding contacts. Would you like to create one now?", "No Group Created", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes) { GroupManager GroupManager = new GroupManager(false); if (GroupManager.ShowDialog() == DialogResult.OK) { ReadData(); } } break; } }
private void groupsbttn_Click(object sender, EventArgs e) { GroupManager GroupManager = new GroupManager(false); if (GroupManager.ShowDialog() == DialogResult.OK) { ReadData(); } }