Beispiel #1
0
        private void button3_Click(object sender, EventArgs e) //handle
        {
            if (listView1.SelectedItems.Count > 0)
            {
                ListViewItem item = listView1.SelectedItems[0];

                PatientsSearchCriteria searchCriteria = new PatientsSearchCriteria();
                long pesel = long.Parse(item.SubItems[4].Text.TrimEnd());
                searchCriteria.setPesel(pesel);
                var x = SQLDoc.GetPatientsList("", "", item.SubItems[4].Text.TrimEnd().ToString());

                panel1.Controls.Clear();
                panel1.Controls.Add(new Handle(x.First().Id_Patient, item.SubItems[0].Text.TrimEnd()));
                panel1.Visible = true;
                panel1.Dock    = DockStyle.Fill;
                panel1.BringToFront();
            }
            else
            {
                MessageBox.Show("Nie wybrano pacjenta");
            }
        }