Esempio n. 1
0
        private void CarregaListBox()
        {
            Modelo.Controle controle = new Modelo.Controle();
            int             id       = Convert.ToInt32(cmbExamesAreas.SelectedValue.ToString());

            controle.GetListaExames(id);
            ltvExames.Clear();
            ltvExames.Columns.Add("ID");
            ltvExames.Columns.Add("Tipo");
            ltvExames.Columns.Add("SubTipo");


            while (controle.Dr.Read())
            {
                ltvExames.Items.Add(new ListViewItem(new string[] { controle.Dr["ID"].ToString(), controle.Dr["Tipo"].ToString(), controle.Dr["SubTipo"].ToString() }));
            }
        }