更改日期格式 [英] Change the date format
本文介绍了更改日期格式的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
谁能帮我解决更改日期格式的功能?
我的日期是mm/dd/yyyy格式,转换后我想要的日期是yyyy-mm-dd格式.
请帮帮我.
在此先感谢您.
Hi,
Can anyone help me out in the changeing date format function?
my date is in mm/dd/yyyy format and after conversion i want the date in yyyy-mm-dd format.
Please help me out.
Thanks in advance.
推荐答案
在C语言中,您必须使用sprintf以所需的格式创建日期.不幸的是,您正在使用C,在C#甚至C ++中,使用它要容易得多.
In C, you''d have to use sprintf to create a date in the format you want. Too bad you''re using C, it''s much easier in C#, or even C++.
感谢您的回复.
我做的. :-O
Thanks for the reply.
I did it. :-O
这篇关于更改日期格式的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文