c# - Storing current time without milliseconds component -
i have timespan object needs hold time, without date. use
datetime.now.timeofday but problem gives time in format
15:51:51.7368329 i don't want milliseconds component. how can trim out?
you can either use datetime.now.hour/minute/second properties or use datetime.now.tostring("hh:mm:ss").
refer here more info: http://msdn.microsoft.com/en-us/library/zdtaw1bw.aspx
Comments
Post a Comment