Beispiel #1
0
        void BtnEditRow_Click(object sender, RoutedEventArgs e)
        {
            MessageTemplates messageTemplate = dgvMessageTemplates.SelectedItem as MessageTemplates;

            if (messageTemplate == null)
            {
                return;
            }
            MessageTemplatesSaveWindow window = new MessageTemplatesSaveWindow(messageTemplate);

            window.ShowDialog();
        }
Beispiel #2
0
        //Дабл клик по строке таблицы - открывает окно редактирования
        private void DgvBid_RowDoubleClick(object sender, MouseButtonEventArgs e)
        {
            DataGridRow row = sender as DataGridRow;

            MessageTemplates template = row.Item as MessageTemplates;

            if (template == null)
            {
                return;
            }

            MessageTemplatesSaveWindow window = new MessageTemplatesSaveWindow(template);

            window.ShowDialog();

            viewSource.View.Refresh();
            dgvMessageTemplates.CurrentCell = new DataGridCellInfo(row.Item, dgvMessageTemplates.CurrentCell.Column);
        }
Beispiel #3
0
        void BtnAdd_Click(object sender, RoutedEventArgs e)
        {
            MessageTemplatesSaveWindow w = new MessageTemplatesSaveWindow();

            w.ShowDialog();
        }