DataFormatString - culture information

Last post 10-07-2008 5:20 AM by srijaya_ramaraju@yahoo.com. 2 replies.

Sort Posts:

  • DataFormatString - culture information

    10-03-2008, 12:16 PM

      Normal 0 false false false MicrosoftInternetExplorer4 /* Style Definitions */ table.MsoNormalTable {mso-style-name:"Table Normal"; mso-tstyle-rowband-size:0; mso-tstyle-colband-size:0; mso-style-noshow:yes; mso-style-parent:""; mso-padding-alt:0in 5.4pt 0in 5.4pt; mso-para-margin:0in; mso-para-margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:10.0pt; font-family:"Times New Roman"; mso-ansi-language:#0400; mso-fareast-language:#0400; mso-bidi-language:#0400;}

    DataFormatString="{0:MM/dd/yyyy}" can be changed to DataFormatString="{0:d}" for taking into consideration the culture information.

     

    But I couldnot find a DataFormatString for conversion of time i.e DataFormatString=" {0:M/dd/yyyy HH:mm}".

     

    I mean how can we modify this format " {0:M/dd/yyyy HH:mm}" to take the current culture.

     

    Would appreciate any help.

    Normal 0 false false false MicrosoftInternetExplorer4 /* Style Definitions */ table.MsoNormalTable {mso-style-name:"Table Normal"; mso-tstyle-rowband-size:0; mso-tstyle-colband-size:0; mso-style-noshow:yes; mso-style-parent:""; mso-padding-alt:0in 5.4pt 0in 5.4pt; mso-para-margin:0in; mso-para-margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:10.0pt; font-family:"Times New Roman"; mso-ansi-language:#0400; mso-fareast-language:#0400; mso-bidi-language:#0400;}

     

     

    Thanks!

  • Re: DataFormatString - culture information

    10-07-2008, 4:57 AM
    Answer

    Hi newasp.netdevelopor,

    Try this:

    DataFormatString="{0:g}"

    Thanks,

    Qin Dian Tang
    Microsoft Online Community Support

    Please remember to mark the replies as answers if they help and unmark them if they provide no help.
  • Re: DataFormatString - culture information

    10-07-2008, 5:20 AM
    Answer

     DateFormatString={0:g}"

    for additional information plz check this link

    http://idunno.org/archive/2004/14/01/122.aspx 

    Thank u

    Baba

    Please remember to click "Mark as Answer" on this post if it helped you.
Page 1 of 1 (3 items)