private void LoadWarehouses()
 {
     DataAccess da = new DataAccess();
     List<warehouse> l = da.GetWarehouses();
     warehouse w = new warehouse();
     w.name = "Все склады";
     l.Add(w);
     edtWarehouse.DataContext = l;
     edtWarehouse.SelectedItem = w;
 }
Exemplo n.º 2
0
 private void LoadWarehouses()
 {
     edtWarehouse.Items.Clear();
     edtWarehouse.Items.Add("Все склады");
     da = new DataAccess();
     List<warehouse> list = da.GetWarehouses();
     foreach (warehouse w in list)
     {
         edtWarehouse.Items.Add(w.name);
     }
     edtWarehouse.SelectedIndex = 0;
 }
Exemplo n.º 3
0
 private void ReloadList()
 {
     DataAccess da = new DataAccess();
     this.DataContext = da.GetWarehouses();
 }