本文介绍了如何在控制台应用程序中将mints添加到datetime的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
实际上我从users表中获取Created_Date_Time并保存在字符串crtdt中。现在我想为Created_Date_Time添加30分钟。是否有可能在控制台应用程序
Actually i am getting Created_Date_Time from users table and saving in the string crtdt. now i want to add 30 min to that Created_Date_Time. is it possible in console application
推荐答案看看下面的例子: Have a look at below example: DateTime currentTime = DateTime.Now; currentTime = currentTime.AddMinutes(30); Label.Text = currentTime.ToString();
以上代码将在当前日期时间增加30分钟。
Above code will add 30 minutes to the current datetime.
更多推荐
如何在控制台应用程序中将mints添加到datetime
发布评论