Auto populate months into cells

Hydestone

Board Regular
Joined
Mar 29, 2010
Messages
137
I have 12 cells E8:P8 that contain months, January, February...

I'd like to type in a month in cell E8 and have the remaining months auto-populate. If E8 is June...F8 would be July...P8 would be May.

Is there an easy way to do this without macros?
 

Excel Facts

Control Word Wrap
Press Alt+Enter to move to a new row in a cell. Lets you control where the words wrap.
First, put the following Custom Format on the range E8:P8:
mmmm

Then, in cell E8 enter the month you want to show first as a date, specifically the first day on the month i.e. enter 1/1 for January.
Then in cell F8, enter the following formula:
Code:
=EDATE(E8,1)
and copy that formula across all the way to cell P8.
 
Upvote 0
That is great Joe, thanks!

Two quick follow up questions

1. Can that formula be modified, so that if the contents in E8 are deleted, nothing populates into cells F8:P8? Do I need an ISBLANK(E8,"",(EDATE(E8,1))) or something similar?
2. I would like cells E16:P16 to have the same information in them that is in E8:P8. So if the cells in row 8 are empty, so are the cells in row 16. Right now the cells in 16 are showing "0" if the cells in 8 are blank.

Thanks in advance.
 
Upvote 0
1. Yes, you could use a formula, but yours is not quite right. To follow the way you were thinking, the formula should look something like this:
Code:
=IF(ISBLANK($E8),"",(EDATE(E8,1)))

2. Should the formulas in row 16 be looking at cell E16 or E8?

If E16, either copy the formula down from row 8 (the rows should adjust automatically).
If you are typing it manually instead of copying, you need to replace the row number references of 8 to 16, i.e.
Code:
=IF(ISBLANK($E16),"",(EDATE(E16,1)))
 
Upvote 0

Forum statistics

Threads
1,223,229
Messages
6,170,881
Members
452,364
Latest member
springate

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