我想增加当前时间的几小时或几分钟 [英] I want add hours or minutes to current time

查看:115
本文介绍了我想增加当前时间的几小时或几分钟的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想增加目前的时间。

例如,我有问题的时间和预期的时间来完成他们

如何添加?

for example, I have the time of the problem and the expected time to complete them
How can I add?

 (DateTime.Now.ToShortDateString()  +.......)


推荐答案

您可以使用其他变量

DateTime otherDate = DateTime.Now.AddMinutes(25);
DateTime tomorrow = DateTime.Now.AddHours(25);

这篇关于我想增加当前时间的几小时或几分钟的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆