我怎样才能获得系统的当前日期格式 [英] how can i Get the current date format of the system

查看:65
本文介绍了我怎样才能获得系统的当前日期格式的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述




我需要在用户请求时间时将客户端系统的日期格式发送到数据库。如何才能获得字符串中的当前系统格式,例如MM / DD / yy HH:MI'等

解决方案

如何对获得最日期 - 时间 - 的客户端-PC-在-ASP-净-C [<一个href =http://stackoverflow.com/questions/7797233/how-to-get-the-date-time-of-client-pc-in-asp-net-ctarget =_ blanktitle =New窗口> ^ ]



如何在asp.net C#中获取客户端PC的日期时间? [ ^ ]



检查链接..希望你能得到这个想法..


DateTime.Now.ToString( DD / MM / yyyy HH:mm);


CultureInfo culture = CultureInfo.CreateSpecificCulture(Request.UserLanguages [0]);

string dd = culture.DateTimeFormat.ShortDatePattern;

Hi
I need to send the date format of the client system to the db when user request for time .how can i get current system format in string eg "MM/DD/yy HH:MI' etc

解决方案

how-to-get-the-date-time-of-client-pc-in-asp-net-c[^]

How to get the date time of client PC in asp.net C#?[^]

Check the links..hope you will get the idea..


DateTime.Now.ToString("dd/MM/yyyy HH:mm");


CultureInfo culture = CultureInfo.CreateSpecificCulture(Request.UserLanguages[0]);
string dd = culture.DateTimeFormat.ShortDatePattern;


这篇关于我怎样才能获得系统的当前日期格式的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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