+ Reply to Thread
Results 1 to 10 of 10

Formula to calculate time

Hybrid View

  1. #1
    Gary Keramidas
    Guest

    Re: Formula to calculate time

    try this

    With Range("a1")
    ..NumberFormat = "MMMM DD, YYYY"
    End With

    --


    Gary


    "accelerator" <gerald.britton@gmail.com> wrote in message
    news:1129923638.911075.240690@o13g2000cwo.googlegroups.com...
    > OK -- Now how can I place a date in a cell as text but with a specific
    > format?
    >
    > e.g.
    >
    > cell a1, formatted as date, currently displays 21/10/05
    >
    > I want to place (via vba) this date as text in cell a2, but I want it
    > to look like
    >
    > 21 Oct 2005
    >
    > or
    >
    > October 21, 2005
    >




  2. #2
    accelerator
    Guest

    Re: Formula to calculate time

    That didn't do it. I used the code:

    Sub test()
    Range("b1") = Range("a1").Value
    With Range("b1")
    ..NumberFormat = "MMMM DD, YYYY"
    End With

    but when I changed the format of the cell to text, I see:

    38646


    How can I convert the date to the above format, then copy the results,
    *as text*, to another cell, formatted as text?


+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1