コード例 #1
0
        private void buttonEdit_Click(object sender, RoutedEventArgs e)
        {
            Customer selected = dataGridCustomers.SelectedItem as Customer;
            if (dataGridCustomers.SelectedItem == null)

            { return; }

            CustomerEdit editWin = new CustomerEdit(selected);
            editWin.Owner = this;
            editWin.ShowDialog();
        }
コード例 #2
0
        private void dataGridCustomers_MouseDoubleClick(object sender, MouseButtonEventArgs e)
        {
            Customer selected = dataGridCustomers.SelectedItem as Customer;
            if (selected.id <1)
            
            { return; }

                CustomerEdit editWin = new CustomerEdit(selected);
                editWin.Owner = this;
                editWin.ShowDialog();
        }