ASP -> Excel Date Problems

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Bryan Harrington

    ASP -> Excel Date Problems

    Hello all.. I've got a table of data that PHB wants to be able to download
    to excel to run pivot tables on.

    No problem.. got all that working.. the catch though is that there is a
    column in the data that shows the Invoice Date, next column shows the
    Invoice Month and Year in the format of mmm-yy.

    Works great in the browser.. when you download it to excel, Excel turns
    SEP-04 into 4-Sep-2004, anybody have a good way to format the date so Excel
    doesn't "fix" it for me?

    Thanks!


  • Ray Costanzo [MVP]

    #2
    Re: ASP -> Excel Date Problems

    You can precede the values with a ' to keep your format.

    <td>'<%=yourDat e%></td>

    Ray at home

    "Bryan Harrington" <news@psacake.c om> wrote in message
    news:%23IuRj4cm EHA.1656@TK2MSF TNGP09.phx.gbl. ..[color=blue]
    > Hello all.. I've got a table of data that PHB wants to be able to download
    > to excel to run pivot tables on.
    >
    > No problem.. got all that working.. the catch though is that there is a
    > column in the data that shows the Invoice Date, next column shows the
    > Invoice Month and Year in the format of mmm-yy.
    >
    > Works great in the browser.. when you download it to excel, Excel turns
    > SEP-04 into 4-Sep-2004, anybody have a good way to format the date so[/color]
    Excel[color=blue]
    > doesn't "fix" it for me?
    >
    > Thanks!
    >
    >[/color]


    Comment

    • Bryan Harrington

      #3
      Re: ASP -&gt; Excel Date Problems

      Thanks Ray..

      That's another Head Slapping DUUHHH! Funny how sometimes the obvious isn't!




      "Ray Costanzo [MVP]" <my first name at lane 34 dot commercial> wrote in
      message news:%231BApAdm EHA.2880@TK2MSF TNGP14.phx.gbl. ..[color=blue]
      > You can precede the values with a ' to keep your format.
      >
      > <td>'<%=yourDat e%></td>
      >
      > Ray at home
      >
      > "Bryan Harrington" <news@psacake.c om> wrote in message
      > news:%23IuRj4cm EHA.1656@TK2MSF TNGP09.phx.gbl. ..[color=green]
      > > Hello all.. I've got a table of data that PHB wants to be able to[/color][/color]
      download[color=blue][color=green]
      > > to excel to run pivot tables on.
      > >
      > > No problem.. got all that working.. the catch though is that there is a
      > > column in the data that shows the Invoice Date, next column shows the
      > > Invoice Month and Year in the format of mmm-yy.
      > >
      > > Works great in the browser.. when you download it to excel, Excel turns
      > > SEP-04 into 4-Sep-2004, anybody have a good way to format the date so[/color]
      > Excel[color=green]
      > > doesn't "fix" it for me?
      > >
      > > Thanks!
      > >
      > >[/color]
      >
      >[/color]


      Comment

      Working...