asp.net - Convert date time format from dd/MM/yyyy to MM/dd/yyyy -


possible duplicate:
convert dd-mm-yyyy mm/dd/yyyyy in c#

i want convert date time format dd/mm/yyyy mm/dd/yyyy in c#

is there suggestion how that?

please try:

string oldstr = "03/12/2011";    string strdate = datetime.parseexact(oldstr, "dd/mm/yyyy",null).tostring("mm/dd/yyyy"); console.writeline(strdate); 

Comments

Popular posts from this blog

javascript - Iterate over array and calculate average values of array-parts -

iphone - Using nested NSDictionary with Picker -

objective c - Newbie question -multiple parameters -