Count Order Numbers and Line numbers based on Person who entered

marty31

New Member
Joined
May 2, 2011
Messages
12
HI

I am trying to calculate the line count of each person based on below info.

Col A is Order Number which can have same number(This needs to be a single reference), then tally the line count Col B) based on order number and person who entered the data (Col C).
Ie small example below, result would be 1 x Order with 16 x Line count By the 1 Person

Any help would be greatly appreciated
A B C
3600243533 10873606 Z00205HE
360024353310873610 Z00205HE
360024353310873612 Z00205HE
360024353310873614 Z00205HE
360024353311239382 Z00205HE
360024353311239382 Z00205HE
360024353311239383 Z00205HE
360024353311239383 Z00205HE
360024353311239384 Z00205HE
360024353311239384 Z00205HE
360024353311239385 Z00205HE
360024353311239385 Z00205HE
360024353311239386 Z00205HE
360024353311239386 Z00205HE
360024353311239387 Z00205HE
360024353311239387 Z00205HE

<colgroup><col><col><col></colgroup><tbody>
</tbody>

<colgroup><col><col><col></colgroup><tbody>
</tbody>
 

Excel Facts

What does custom number format of ;;; mean?
Three semi-colons will hide the value in the cell. Although most people use white font instead.
VBA solution
Code:
Sub t()
With ActiveSheet
    .Range("A1", .Cells(Rows.Count, 1).End(xlUp)).AdvancedFilter xlFilterCopy, , .Cells(Rows.Count, 1).End(xlUp).Offset(2, 1), True
        For Each c In .Cells(Rows.Count, 2).End(xlUp).CurrentRegion.Offset(1)
            If c <> "" Then
                .Cells(Rows.Count, 5).End(xlUp)(2) = CStr(c.Value)
                .Cells(Rows.Count, 5).End(xlUp).Offset(, 1) = Application.CountIf(Range("A:A"), c.Value)
            End If
        Next
    .Cells(Rows.Count, 2).End(xlUp).CurrentRegion.ClearContents
End With
End Sub

Puts results in columns E and F starting on row 2.
 
Last edited:
Upvote 0

Forum statistics

Threads
1,214,653
Messages
6,120,750
Members
448,989
Latest member
mariah3

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