Ejemplo n.º 1
0
 public static void DisplayModal(DateTime date, string trackCode, string horseName, int raceNumber)
 {
     if (!DateOfRace.RaceExistsInDb(trackCode, date, raceNumber))
     {
         MessageBox.Show("Sorry, race does not exist in the data base!");
     }
     else
     {
         var form = new ShowFractionsForTheDayForm(date, trackCode, horseName, raceNumber, null);
         form.ShowDialog();
     }
 }
Ejemplo n.º 2
0
 public static void DisplayModal(BrisPastPerformance pp)
 {
     DateTime date = pp.Date;
     string trackCode = pp.TrackCode;
     string horseName = pp.Parent.Name;
     int raceNumber = Convert.ToInt32(pp.RaceNumber);
     if (!DateOfRace.RaceExistsInDb(trackCode, date, raceNumber))
     {
         string caption = string.Format("{0}, {1}", trackCode, Utilities.GetFullDateString(Utilities.GetDateInYYYYMMDD(date)));
         MessageBox.Show("Sorry, race does not exist in the data base!", caption);
     }
     else
     {
         var form = new ShowFractionsForTheDayForm(date, trackCode, horseName, raceNumber, pp);
         form.ShowDialog();
     }
 }