Example #1
0
        private void editBtn_Click(object sender, RoutedEventArgs e)
        {
            var dialog = new AddEditDialog((sender as Button).CommandParameter as InfoCard);

            if (dialog.ShowDialog() == true)
            {
                (DataContext as MainVM).AddEditDataCommand.Execute(dialog.EditCard);
            }
        }
Example #2
0
        private void addBtn_Click(object sender, RoutedEventArgs e)
        {
            var dialog = new AddEditDialog();

            if (dialog.ShowDialog() == true)
            {
                (DataContext as MainVM).AddEditDataCommand.Execute(dialog.EditCard);
            }
        }