private void ViewTask_Click(object sender, EventArgs e) { if (ProjectID.SelectedItem == null || Tasks.SelectedItem == null) { MessageBox.Show("All FiledsAre Requierd"); return; } String selected = Tasks.SelectedItem.ToString().ToString(); int id = Tools.getId(selected); if (Admin) { ViewTaskForm viewTaskForm = new ViewTaskForm(adminActionForm, id); viewTaskForm.Show(); adminActionForm.Hide(); } else { ViewTaskForm viewTaskForm = new ViewTaskForm(userActionForm, id); viewTaskForm.Show(); adminActionForm.Hide(); } }
private void EditProject_Click(object sender, EventArgs e) { EditProjectForm editProjectForm = new EditProjectForm(adminActionForm); editProjectForm.Show(); adminActionForm.Hide(); }