ASP .NET with C#:month not displayed for BoundField in GridVeiw

Discussion in 'General Computer Support' started by gerinjacob, Sep 3, 2006.

  1. gerinjacob

    gerinjacob

    Joined:
    Sep 3, 2006
    Messages:
    1
    Likes Received:
    0
    Hi,
    I used GridView for one of my web application,

    The BoundField code is as follows:
    <asp:BoundField DataField="Scheduleddate" HeaderText="Quiz Scheduled on" SortExpression="Scheduleddate" DataFormatString="{0:mm/dd/yyyy}" HtmlEncode="false" />

    In that i wanted Date to be displayed in mm/dd/yyyy format. The format is working fine, but month is dispalyed as "00". For eg. 00/03/2006

    Can anyone help me?:help:

    Regards,
    Gerin
     
    gerinjacob, Sep 3, 2006
    #1
    1. Advertisements

  2. gerinjacob

    WhyDoesItDoThat

    Joined:
    Nov 10, 2006
    Messages:
    1
    Likes Received:
    0
    change mm to MM
     
    Last edited: Nov 10, 2006
    WhyDoesItDoThat, Nov 10, 2006
    #2
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.