ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Generating date from day, month year (https://www.excelbanter.com/excel-worksheet-functions/241296-generating-date-day-month-year.html)

Ned Harrison[_2_]

Generating date from day, month year
 
Hello all,

Is there any way I can generate a date in one cell, from 3 other separate
cells - one each for day, month, year? i.e. if you enter (for example) '01'
in A1, 'September' in A2 and '2009' in A3, then in B1 it shows '01/09/2009'.
Alternatively, is there a way I can generate the month from the date - so if
you enter (for example) '01/09/2009' in A1, it shows 'September' in B1?
Many thanks in advance for your help,
N

joeu2004

Generating date from day, month year
 
"Ned Harrison" wrote:
Is there any way I can generate a date in one cell, from 3 other separate
cells - one each for day, month, year? i.e. if you enter (for example)
'01'
in A1, 'September' in A2 and '2009' in A3, then in B1 it shows
'01/09/2009'.


I assume the apostrophes (single quotes) are not really in the cell. And I
assume you want the date value (number) 1/9/2009, not text. Try:

=--(A1&A2&A3)

formatted as Date or the custom format mm/dd/yyyy, depending on Regional and
Language settings.

On the off-chance that you want the text "01/09/2009", try:

=text(A1&A2&A3, "mm/dd/yyyy")


Alternatively, is there a way I can generate the month from the date - so
if
you enter (for example) '01/09/2009' in A1, it shows 'September' in B1?


=text(A1, "mmmm")



JP Ronse

Generating date from day, month year
 
Hi Ned,

For the date, try

=DATEVALUE(A1&"/"&A2&"/"&A3) with A1 = day, A2 = September, A3 = year

To get the month of a given date, try to format the cell: number, custom:
'mmmm' (without the quotes).

Wkr,

JP

"Ned Harrison" wrote in message
...
Hello all,

Is there any way I can generate a date in one cell, from 3 other separate
cells - one each for day, month, year? i.e. if you enter (for example)
'01'
in A1, 'September' in A2 and '2009' in A3, then in B1 it shows
'01/09/2009'.
Alternatively, is there a way I can generate the month from the date - so
if
you enter (for example) '01/09/2009' in A1, it shows 'September' in B1?
Many thanks in advance for your help,
N




Jacob Skaria

Generating date from day, month year
 
Col A Col B
1 =DATEVALUE(A1&"-"&A2&"-"&A3)
September =TEXT(B1,"mmmm")
2009

If this post helps click Yes
---------------
Jacob Skaria


"Ned Harrison" wrote:

Hello all,

Is there any way I can generate a date in one cell, from 3 other separate
cells - one each for day, month, year? i.e. if you enter (for example) '01'
in A1, 'September' in A2 and '2009' in A3, then in B1 it shows '01/09/2009'.
Alternatively, is there a way I can generate the month from the date - so if
you enter (for example) '01/09/2009' in A1, it shows 'September' in B1?
Many thanks in advance for your help,
N


Ned Harrison[_2_]

Generating date from day, month year
 
Thanks all - that's brilliant.
Cheers,
Ned


All times are GMT +1. The time now is 11:46 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com