• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

VBA coding for creating summary report needed

Noelcab

New Member
In sheet1 column A are the dates and on column D are the names of people.
I would like to generate a summary report on Sheet 2 using VBA code. I know that this can be done with Pivot table. however I need vbacodes for it.
I was able to get a summary of occurences of the dates. however i need the breakdown of it per person per day.

Sample of sheet 1 and it goes on to a long list, the names are constant variables
DateItemPriceName
8/18/2014Bam
8/18/2014Joe
8/18/2014Jane
8/18/2014Drew
8/18/2014John
8/18/2014Darwin
8/18/2014Angel
8/18/2014Eric
8/18/2014Ken
8/18/2014Vin
8/18/2014Don
8/18/2014Sam

I need on sheet 2 to produce

DatetotalBamjoejanedrewjohndarwinangelerickenvindonsamaprilstacey
8/18/201475
8/19/201489
8/20/201486
8/21/201494
8/22/2014108
8/25/2014176
8/26/2014176
8/27/2014174
8/28/2014206
8/29/2014193
9/2/2014209
9/3/201496
9/4/2014261
9/5/2014195
9/12/20141
9/16/20144
 

Attachments

  • SAMPLE2.xlsm
    94 KB · Views: 6
NoelCab

Firstly, Welcome to the Chandoo.org Forums

On sheet1 there is no Data to add up to get a value of 75 for Bam on 18/8/14

So I have assumed It will be in Column C

Then you can use in: Sheet2!C2:
=SUMPRODUCT((Sheet1!$D$2:$D$2144=C$1)*(Sheet1!$A$2:$A$2144=$A2)*(Sheet1!$C$2:$C$2144))

Copy across and down
 
Back
Top