开发者

Dateformat for ajax calendar extender to create (e.g.) 1980/01/01?

I have tried yyyy/MM/dd but this returns 1980/1/1, which will fail the check against cult开发者_如何学Pythonureinfo format in .NET


try with this it adds the 0 so you will have 1980/01/01

 DateTime dt = new DateTime(1980, 01, 01);
 string result = String.Format("{0:yyyy/MM/dd}", dt);

hope it helps

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜