示例#1
0
        private void BtFinish_Click(object sender, RoutedEventArgs e)
        {
            if (CompetitionsToSelect.SelectedItem == null)
            {
                MessageBox.Show(Properties.Resources.NothingSelected);
                return;
            }

            /*try {*/
            _competition = _competitionService.ListCompetitionsToInscribeObject(_athlete)
                           .ElementAt(CompetitionsToSelect.SelectedIndex);

            if (_enrollService.IsAthleteInComp(_competition, _athlete))
            {
                MessageBox.Show(Properties.Resources.PreviouslyEnrolled);
                return;
            }

            new DialogPayment(_athlete, _competition).ShowDialog();
            LoadData(TxDni.Text);

            /*} catch (ApplicationException) {
             *  MessageBox.Show(Properties.Resources.PreviouslyEnrolled);
             * }*/
        }