Covert two cell date 2024, Aug into Aug-2024

slam

Well-known Member
Joined
Sep 16, 2002
Messages
893
Office Version
  1. 365
  2. 2019
Hi gang - happy Friday!

I have a system that exports dates into two rows starting in column D. Row 1 is the year 2024, and row 2 is the month, August, formatted as General. Is there an easy way to turn these into an actual date in row 3?

Thanks
 

Excel Facts

Format cells as date
Select range and press Ctrl+Shift+3 to format cells as date. (Shift 3 is the # sign which sort of looks like a small calendar).
A valid date requires three pieces:
1. Year
2. Month
3. Day

You can format it any way you like, to hide the day portion (i.e. Aug-2024). But in order for it to be stored as a valid date, it also needs the day piece.
So what day do you want to use? 1, the first day of the month?
 
Upvote 1
=DATEVALUE("01/"&D2&"/"&D1)

Book9
D
12024
2august
38/1/24
Sheet1
Cell Formulas
RangeFormula
D3D3=DATEVALUE("01/"&D2&"/"&D1)
 
Upvote 1
Solution
Hi

Joe, yes, I should have mentioned that. 1st of month is good.

etaf, thank you for the solution. Perfect!
 
Upvote 0
If you don't specify the day, Excel will default to 1:

=--(D2 & " " &D1)

Format as date
 
Upvote 1

Forum statistics

Threads
1,221,526
Messages
6,160,340
Members
451,637
Latest member
hvp2262

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top