VBA determining 'Adults' and 'Children' based on Reference Number of Cases

herman925

New Member
Joined
Apr 9, 2017
Messages
24
The basic premise of the code I seek help is that

1) Every family is assigned a reference number of 7 digits (e.g. 1001-012)
2) Family is a mixture of different number of adults and children, where adult >18 and children <18
3) I tried using SMALL, which will look something like
4) There is a Masterlist of all the details of individual clients

Code:
=INDEX(Table_MIS[BIRTHDAY],SMALL(IF(A2=Table_MIS[CASENAME],ROW(Table_MIS[CASENAME])-MIN(ROW(Table_MIS[CASENAME]))+1,""),1))

Where Birthday is obviously the birthday
And Casename meaning the reference number of the family

I want to do something like this:

A
B
C
D
1
Reference Number
Number of Children
Number of Adults
Total Clients
2
1001-012
???
????
=sum(B2:C2)

<tbody>
</tbody>

Any help is greatly appreciated!
 

Excel Facts

Excel Can Read to You
Customize Quick Access Toolbar. From All Commands, add Speak Cells or Speak Cells on Enter to QAT. Select cells. Press Speak Cells.

Forum statistics

Threads
1,213,491
Messages
6,113,963
Members
448,536
Latest member
CantExcel123

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