public void sectionFormsDataLoad() { DataSet loadData = new DataSet(); string tmp = formsBox.Text; if (srv.getSectionFormsList(tmp, out loadData)) { sectionFormsBox.Enabled = true; foreach (DataRow item in loadData.Tables[0].Rows) { int id = Convert.ToInt16(item["section_forms_id"].ToString()); int fid = Convert.ToInt16(item["forms_id"].ToString()); string name = item["section_forms_name"].ToString(); CSectionForm sectionItem = new CSectionForm(id, fid, name); sectionFormItems.Add(sectionItem); sectionFormsBox.Items.Add(sectionItem); } } else { MessageBox.Show("Нет раздела формы соответствующей данной форме", "Предупреждение", MessageBoxButtons.OK, MessageBoxIcon.Warning); } }