calculate max age

prlondhe

Board Regular
Joined
Jan 4, 2014
Messages
54
CLIENT CODESUB CODECOMPANYPOLICY TYPEPOLCY SUB TYPEVEHICLE NUMBERSERIAL NUMBERINSURED NAMEBIRTH DATESUM INSUREDAGEmax age
X1045NIAMEDICLAIMINDIVIDUAL1xyz21/10/1957200,00059
X1045NIAMEDICLAIMINDIVIDUAL2abc07/08/1959200,00057

<colgroup><col span="7"><col><col><col><col><col></colgroup><tbody>
</tbody>

Hi

I have the above file which contains age for each individual.
there can many records with client code.
Now I want to calculate the max age for each client code in column a with vba. Can somebody help
 

Excel Facts

Get help while writing formula
Click the italics "fx" icon to the left of the formula bar to open the Functions Arguments dialog. Help is displayed for each argument.
Maybe you could tell us how you get the max age?

EDIT: Must have missed the client code part
 
Last edited:
Upvote 0
Try this in cell L1:

=MAX(IF($A$2:$A$4="X104",$K$2:$K$4)) and enter with CTRL-SHFT-ENTER to make it appear like this: {=MAX(IF($A$2:$A$4="X104",$K$2:$K$4))}

Then copy down.

You'll obviously need to adjust the ranges as necessary before copying.
 
Upvote 0

Forum statistics

Threads
1,215,028
Messages
6,122,749
Members
449,094
Latest member
dsharae57

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