예제 #1
0
파일: FrmBack.cs 프로젝트: Ghcsm/Wh_Fzg
        private void InIHouse()
        {
            List <V_HouseSet> HouseEc = new List <V_HouseSet>();
            DataTable         dt      = T_Sysset.GetHouseName();

            if (dt == null || dt.Rows.Count <= 0)
            {
                return;
            }
            foreach (DataRow dr in dt.Rows)
            {
                V_HouseSet House = new V_HouseSet();
                House.HouseID   = Convert.ToInt32(dr["id"].ToString());
                House.HouseName = dr["HOUSENAME"].ToString();
                HouseEc.Add(House);
            }
            cBoxKf.Items.Clear();
            cBoxKf.Items.AddRange(HouseEc.ToArray());
            cBoxKf.SelectedItem  = HouseEc;
            cBoxKf.SelectedIndex = 0;
        }