• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 242
  • Last Modified:

Format as Dates

Experts,

I have a formula: =B7 & " - " &B8
the cells B7 and B8 are date formats.
I need the formula to return the date format as well but it returns the date as a number.  

How can I change the format from that number that is displaying to a date format of DD-MMM-YY?

thank you
0
pdvsa
Asked:
pdvsa
  • 2
  • 2
1 Solution
 
kgerbChief EngineerCommented:
I think this will work.

= TEXT(B7,"DD-MMM-YY") & " - " & TEXT(B8,"DD-MMM-YY")

Kyle
0
 
BusyMamaCommented:
I'm a little confused, for two reasons.

First, the formula you are using is a "concatenation" method, meaning no mathematical calculations should actually be being performed - the result should be showing Date1 - Date2, but dates would be converted to number format.

Second, can you give an example of what date value you would expect to be returned if in cell B7 was 1/2/2011 and in cell B8 was 1/1/2011?  One day between the dates.  What is your expected outcome in your formula cell?
0
 
BusyMamaCommented:
Ah, I see, using Kyle's method.  I thought you wanted just one date returned!  Silly me.
0
 
pdvsaAuthor Commented:
that was it.  thank you
0
 
kgerbChief EngineerCommented:
You're welcome.  Thanks for the points and the grade!

Kyle
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now