/* private async Task CheckForUpdates() * { * using(var manager = new UpdateManager(@"\\192.168.1.10\software\Wagner\IvyUpdate\Releases")) * { * await manager.UpdateApp(); * } * }*/ //Search button --> will find Manufacturer and Supplier Number and select it in the DataGrid private void BtnSuchen_Click(object sender, System.Windows.RoutedEventArgs e) { dtGridInventarListe.ItemsSource = null; /* ObservableCollection<Inventar> FoundList = InventarSearch.AdvancedSearchList(this, inv); * dtGridInventarListe.ItemsSource = FoundList;*/ CheckBox[] checkBoxes = new CheckBox[7]; checkBoxes[0] = cbxSupplier; checkBoxes[1] = cbxManufacturer; checkBoxes[2] = cbxCategory; checkBoxes[3] = cbxDescription; checkBoxes[4] = cbxLocation; checkBoxes[5] = cbxManufacturerPartNumber; checkBoxes[6] = cbxSupplierPartNumber; dtGridInventarListe.ItemsSource = null; dtGridInventarListe.ItemsSource = ArticleController.GetAdvancedSearchList(checkBoxes, txtSuchfeld.Text); //ArticleController.FoundArticles(txtSuchfeld.Text, checkBoxes); lblRowsCount.Content = "Articles count: " + dtGridInventarListe.Items.Count; //MessageBox.Show(ExpertSmartSearch.advancedQuery(txtSuchfeld.Text)); }
private void TxtSuchfeld_KeyUp(object sender, KeyEventArgs e) { dtGridInventarListe.ItemsSource = null; if (e.Key == Key.Enter) { CheckBox[] checkBoxes = new CheckBox[7]; checkBoxes[0] = cbxSupplier; checkBoxes[1] = cbxManufacturer; checkBoxes[2] = cbxCategory; checkBoxes[3] = cbxDescription; checkBoxes[4] = cbxLocation; checkBoxes[5] = cbxManufacturerPartNumber; checkBoxes[6] = cbxSupplierPartNumber; dtGridInventarListe.ItemsSource = null; dtGridInventarListe.ItemsSource = ArticleController.GetAdvancedSearchList(checkBoxes, txtSuchfeld.Text); lblRowsCount.Content = "Articles count: " + dtGridInventarListe.Items.Count; } if (e.Key == Key.Escape) { txtSuchfeld.Text = ""; } }