dateTimePicker 获取自定义日期值

MessageBox.Show(dateTimePicker1.Value.ToString("yyyy-MM-dd 00:00:00"));

 

 

dateTimePicker1.Value.ToString("yyyy-MM-dd   :   HH:mm:ss")

 

 

MessageBox.Show(string.Format("{0:d}",dateTimePicker1.Value));

posted @ 2009-04-03 10:43  yongbin621  阅读(4162)  评论(0编辑  收藏  举报