System.DateTime.Now 24小时制。

this.Label6.Text = "当前时间:" + System.DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");    2014-11-29 15:03:04

 

this.Label6.Text = "当前时间:" + System.DateTime.Now.ToString("yyyy-MM-dd hh:mm:ss");    2014-11-29 03:03:04

posted @ 2019-05-05 15:43  ProZkb  阅读(591)  评论(0编辑  收藏  举报