private void _btnNewStaff_Click(object sender, RoutedEventArgs e) { AddStaff win = new AddStaff(); win.ShowDialog(); _datagridStaff.ItemsSource = db.Staffs.ToList(); }
private void btnNewStaff_Click(object sender, EventArgs e) { _as.ShowDialog(); }
private void AddButon_Click (object sender, RoutedEventArgs e) { _BUSY_INDICATOR.IsBusy=false; var wind = new AddStaff(Guid.Empty) { Owner=Window.GetWindow(this) }; wind.ShowDialog(); UpdateData(); }
private void Modifier_OnClick (object sender, RoutedEventArgs e) { var menuItem = (MenuItem)e.Source; var menu = (ContextMenu)menuItem.Parent; var list = (ListBox)menu.PlacementTarget; if(list?.SelectedValue==null) return; _BUSY_INDICATOR.IsBusy=false; var wind = new AddStaff((Guid) list.SelectedValue) { Owner=Window.GetWindow(this) }; wind.ShowDialog(); UpdateData(); }