如何在我的c#应用程序中设置自己的时间,这取决于系统时间 [英] how to set own time in my c# application which does not depends on system time

查看:59
本文介绍了如何在我的c#应用程序中设置自己的时间,这取决于系统时间的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在我的c#应用程序中设置自己的时间,这取决于系统时间

how to set own time in my c# application which does not depends on system time

推荐答案

最明显的方法是获取表示偏移的时间系统时间(例如,DateTime.Now,如果你想要一个从0开始的计时器),然后只是保持显示DateTime.Now - yourValue
The most obvious way is to grab a time that represents the offset from the system time ( for example, DateTime.Now if you want a timer starting at 0 ) and then just keep show DateTime.Now - yourValue


这篇关于如何在我的c#应用程序中设置自己的时间,这取决于系统时间的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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