Sunday, 8 September 2013

not getting the complete date in M/D/YYYY with DateTime.Now.ToString method

not getting the complete date in M/D/YYYY with DateTime.Now.ToString method

I am using datetime.now.tostring method with the format M/D/YYYY but not
getting the desired output . i m getting 9/D/YYYY. please help. Cureently
my code sniped is like the below:
DateTime d = DateTime.Now.Date;
string Date = d.ToString("M/D/YYYY");

No comments:

Post a Comment