private void BtnAdd_OnClick(object sender, RoutedEventArgs e) { var window = new GoodWindow(null); window.Owner = this; window.ShowDialog(); lvGoods.Items.Clear(); using (var uow = new UnitOfWork()) { var goods = uow.Goods.GetLVGoods(); foreach (var good in goods) { AddGoodToListView(good); } } }