?
Solved

Format as Dates

Posted on 2011-09-27
5
Medium Priority
?
232 Views
Last Modified: 2012-05-12
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
Comment
Question by:pdvsa
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 12

Accepted Solution

by:
kgerb earned 2000 total points
ID: 36709361
I think this will work.

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

Kyle
0
 
LVL 7

Expert Comment

by:BusyMama
ID: 36709377
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
 
LVL 7

Expert Comment

by:BusyMama
ID: 36709386
Ah, I see, using Kyle's method.  I thought you wanted just one date returned!  Silly me.
0
 

Author Closing Comment

by:pdvsa
ID: 36709396
that was it.  thank you
0
 
LVL 12

Expert Comment

by:kgerb
ID: 36709408
You're welcome.  Thanks for the points and the grade!

Kyle
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes how to use a set of graphical playing cards to create a Draw Poker game in Excel or VB6.
If you need to forecast numbers -- typically for finance -- the Windows and Mac versions of Excel 2016 have a basket of tools to get the job done.
This Micro Tutorial will demonstrate how to use longer labels with horizontal bar charts instead of the vertical column chart.
This Micro Tutorial will demonstrate how to create pivot charts out of a data set. I also added a drop-down menu which allows to choose from different categories in the data set and the chart will automatically update.

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question