Exemplo n.º 1
0
        private void dgAccountListeleme_MouseDoubleClick(object sender, MouseButtonEventArgs e)
        {
            if (dgAccountListeleme.SelectedItem == null)
            {
                return;
            }

            AccountContract selectedAccount = dgAccountListeleme.SelectedItem as AccountContract;

            AccountAdd.MainWindow accountAddWindow = new AccountAdd.MainWindow(selectedAccount);
            accountAddWindow.Show();


            // MessageBox.Show(string.Format("The Person you double clicked on is - Id: {0}, Address: {1}, Surname: {2}", selectedPerson.Id, selectedPerson.Name, selectedPerson.SurName));
        }
Exemplo n.º 2
0
        private void btnOpenAccount_Click(object sender, RoutedEventArgs e)
        {
            if (dgPortalMusteriListeleme.SelectedItem == null)
            {
                MessageBox.Show("Lütfen gridden müşteri seçiniz.", "Message", MessageBoxButton.OK, MessageBoxImage.Error);
                return;
            }
            CustomerContract selectedCustomer = dgPortalMusteriListeleme.SelectedItem as CustomerContract;

            AccountAdd.MainWindow addAccountAddWindow = new AccountAdd.MainWindow(new AccountContract()
            {
                AccountOwnerId = (int)selectedCustomer.Id
            });
            addAccountAddWindow.Show();
        }