Grabbing the latest data from a Column based on a cell

ashringg

New Member
Joined
Nov 2, 2023
Messages
13
Office Version
  1. 2016
Platform
  1. Windows
Hello,

Calling all help! I cannot figure out a formula to make this work. I am tracking my pups got their medical history and I would like it to auto-give me a expiration date based on the most recent date i entered where its checked (I added checkboxes into columns- not sure if that is a good approach)

Instead of manually changing that date per column item, can you suggest an approach to execute my idea?
I attached a picture of the sample.
dog records.xlsx
ABCDEF
2AgeDateRabiesOther
36410/12/2021
47510/15/2022
5863/23/2023
6
7
8
9
10WhatNextPast Due
11RabiesFind Column to match cell from coloumn A Then grabs the cell most recent check in the colomn Finally adds the date in column C and adds 365 days=IF(TODAY()-B11="-#","PAST DUE","")
12Other""
Sheet6
Cell Formulas
RangeFormula
A3:A8A3=IF($C3=""," ",YEAR($C3)-2015)
B3:B8B3=IF($C3=""," ",YEAR($C3)-2017)
 

Attachments

  • Pet History Snip.png
    Pet History Snip.png
    13.1 KB · Views: 11

Excel Facts

Move date out one month or year
Use =EDATE(A2,1) for one month later. Use EDATE(A2,12) for one year later.
Hi @ashringg

I re-designed your table to make it a bit easier to handle. Here's what I got. It should do the job.
Please let me know if this is what you were looking for and if that's a hit, please mark it as solution.

Book3.xlsx
ABCDE
1UPCOMING EVENTS
2WhatNextPast Due
3Rabies10/15/2023PAST DUE
4Other3/22/2024 
5
6HISTORY
7Dog Mom (born 2015)Dog Daug (born 2017)
8AgeDateRabiesOther
96410/12/2021xx
107510/15/2022x
11863/23/2023x
12  
13
14
15
16
17
18
19
20
21
22
23
Sheet1
Cell Formulas
RangeFormula
B3B3= LOOKUP("x",D9:D23,C9:C23) + 365
C3:C4C3= IF(B3<TODAY(),"PAST DUE","")
B4B4= LOOKUP("x",E9:E23,C9:C23) + 365
A9:A12A9= IF( $C9="","",YEAR($C9)-2015)
B9:B12B9= IF( $C9="","",YEAR($C9)-2017)
Cells with Conditional Formatting
CellConditionCell FormatStop If True
C3:C4Cell Valuecontains "PAST DUE"textNO
 
Last edited:
Upvote 1
Solution
Hi @ashringg

I re-designed your table to make it a bit easier to handle. Here's what I got. It should do the job.
Please let me know if this is what you were looking for and if that's a hit, please mark it as solution.

Book3.xlsx
ABCDE
1UPCOMING EVENTS
2WhatNextPast Due
3Rabies10/15/2023PAST DUE
4Other3/22/2024 
5
6HISTORY
7Dog Mom (born 2015)Dog Daug (born 2017)
8AgeDateRabiesOther
96410/12/2021xx
107510/15/2022x
11863/23/2023x
12  
13
14
15
16
17
18
19
20
21
22
23
Sheet1
Cell Formulas
RangeFormula
B3B3= LOOKUP("x",D9:D23,C9:C23) + 365
C3:C4C3= IF(B3<TODAY(),"PAST DUE","")
B4B4= LOOKUP("x",E9:E23,C9:C23) + 365
A9:A12A9= IF( $C9="","",YEAR($C9)-2015)
B9:B12B9= IF( $C9="","",YEAR($C9)-2017)
Cells with Conditional Formatting
CellConditionCell FormatStop If True
C3:C4Cell Valuecontains "PAST DUE"textNO
This is perfect. Thank you very much!
 
Upvote 0
Hi @ashringg

I re-designed your table to make it a bit easier to handle. Here's what I got. It should do the job.
Please let me know if this is what you were looking for and if that's a hit, please mark it as solution.

Book3.xlsx
ABCDE
1UPCOMING EVENTS
2WhatNextPast Due
3Rabies10/15/2023PAST DUE
4Other3/22/2024 
5
6HISTORY
7Dog Mom (born 2015)Dog Daug (born 2017)
8AgeDateRabiesOther
96410/12/2021xx
107510/15/2022x
11863/23/2023x
12  
13
14
15
16
17
18
19
20
21
22
23
Sheet1
Cell Formulas
RangeFormula
B3B3= LOOKUP("x",D9:D23,C9:C23) + 365
C3:C4C3= IF(B3<TODAY(),"PAST DUE","")
B4B4= LOOKUP("x",E9:E23,C9:C23) + 365
A9:A12A9= IF( $C9="","",YEAR($C9)-2015)
B9:B12B9= IF( $C9="","",YEAR($C9)-2017)
Cells with Conditional Formatting
CellConditionCell FormatStop If True
C3:C4Cell Valuecontains "PAST DUE"textNO
Curious, do you know if there is a formula that would say to find the column that matches cell A1 ("Rabies"), then LOOKUP "x" based on that?
 
Upvote 0

Forum statistics

Threads
1,215,076
Messages
6,122,988
Members
449,093
Latest member
Mr Hughes

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