Auto Date Based On Value

shah_ir85

New Member
Joined
May 8, 2016
Messages
39
Hello Guys
ABCD
NameCurrent AppointmentAgeNext Appointmen
James12 Dec 203912 Dec 22
John12 Jan 204012 Jan 21
Moon10 Jul 204110 Jul 22

How to make formula at D column,
if the age is 40 or over, Next Appointmen is 1 year later
If the age 39 and below, Next Appointmen is 2 years later

Please help me
 

Some videos you may like

Excel Facts

Can Excel fill bagel flavors?
You can teach Excel a new custom list. Type the list in cells, File, Options, Advanced, Edit Custom Lists, Import, OK

Peter_SSs

MrExcel MVP, Moderator
Joined
May 28, 2005
Messages
47,926
Office Version
  1. 365
Platform
  1. Windows
I'm not sure why your last example is 2 years later when the age is 41, but try this.

20 09 01.xlsm
ABCD
1NameCurrent AppointmentAgeNext Appointmen
2James12-Dec-203912-Dec-22
3John12-Jan-204012-Jan-21
4Moon10-Jul-204110-Jul-21
Next Appt
Cell Formulas
RangeFormula
D2:D4D2=EDATE(B2,IF(C2<40,24,12))
 
Solution

Watch MrExcel Video

Forum statistics

Threads
1,122,947
Messages
5,599,012
Members
414,273
Latest member
vikas007

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
Top