Format as Dates


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
pdvsaProject financeAsked:
Who is Participating?
kgerbConnect With a Mentor Chief EngineerCommented:
I think this will work.

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

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?
Ah, I see, using Kyle's method.  I thought you wanted just one date returned!  Silly me.
pdvsaProject financeAuthor Commented:
that was it.  thank you
kgerbChief EngineerCommented:
You're welcome.  Thanks for the points and the grade!

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.