private void EditReservation(object sender, EventArgs e) { DateTime t = endedit.Value; string st = ""; if (t.Day < 10) { st += "0"; } st += t.Day.ToString(); if (t.Month < 10) { st += "0"; } st += t.Month.ToString(); st += t.Year.ToString(); f.EditReservation(st, IDEdit.Text); MessageBox.Show("Done "); }