Exemple #1
0
        private void UpdateButton_Click(object sender, RoutedEventArgs e)
        {
            if (TableView.SelectedIndex == -1)
            {
                Error.Text = "Не выбрана строка!";

                return;
            }
            Error.Text = "";


            System.Data.DataRowView selectedRow = (System.Data.DataRowView)TableView.SelectedItems[0];
            int landId = (int)selectedRow.Row[0];

            AddLand edit = new AddLand(this, 2, landId);

            edit.Show();
        }
Exemple #2
0
        private void AddButton_Click(object sender, RoutedEventArgs e)
        {
            AddLand add = new AddLand(this, 1, 0);

            add.Show();
        }