lookup & count with multiple criteria

Montanes

New Member
Joined
Aug 18, 2016
Messages
42
Office Version
  1. 365
Platform
  1. Windows
Hi,

I would appreciate any help with the following problem i have:

In 'Sheet1' i have 3 populated columns with the headings 'Date', 'Agent' and 'Stock' and the relevant data underneath to include the dd/mm/yyyy, the selling agents name and the stock code of the item sold.

In 'Sheet2' i have 2 tables with the 24 sales agents names in ColumnA and the 24 stock codes along the header row for each table.

I am desperate for an equation that counts how often the stock item in the header row is sold by each agent in ColumnA and in the month of my choosing or YTD.

So for the first table i may for example have the month in 'Sheet2 A1' that i can change as and when required. Then with the 24 sales agents name underneath in column A, and the stock codes along row 1 starting in column B.

What i then need in B2 is an equation that will count how often the stock code appears in 'Sheet1 C:C' assuming the date in 'Sheet1 A:A' matches the month (i have chosen in 'Sheet2 A1') and the sales agents name in 'Sheet1 B:B.

In the second table i just need the same without the date restriction so as to show the same data YTD as opposed to an individual month.
 

Excel Facts

How to create a cell-sized chart?
Tiny charts, called Sparklines, were added to Excel 2010. Look for Sparklines on the Insert tab.

Forum statistics

Threads
1,223,883
Messages
6,175,167
Members
452,615
Latest member
bogeys2birdies

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