double n = 0; DateTime origintime = DateTime.FromOADate(0); // origintime.ToString()等于“1899-12-30 0:00:00” while (DateTime.FromOADate(n) != Command.Win.dp_date.SelectedDate) { n += 1; } //TaskDialog.Show("test", DateTime.FromOADate(n).ToShortDateString()); TaskDialog.Show("test", n.ToString());