12:DateTime.Now.ToString("hh:mm:ss") 24:DateTime.Now.ToString("HH:mm:ss") 转载于:https://www.cnblogs.com/armanda/p/3747710.html