You can use Pivot Table to do this.
Use Items as Row Field.
Use Date as Column and Data Field (Count of Date).
Using VBA
Assuming that Items and Date are in worksheet "Sheet1" starting in cell A1, the pivot table is created in a worksheet "Sheet2" starting in cell A3 in the active workbook.
Sub createPivotTableReport()
Set wsData = ActiveWorkbook.Worksheets("Sheet1")
Set wsReport = ActiveWorkbook.Worksheets("Sheet2")
Set rngData = wsData.UsedRange
Set rngReport = wsReport.Range("a3")
Set pvtCache = ActiveWorkbook.PivotCaches.Add(xlDatabase, rngData.Address(True, True, 1, True))
Set pvtTable = pvtCache.CreatePivotTable(rngReport)
pvtFieldsRow = Array("Items")
pvtFieldsCol = Array("Date")
pvtTable.AddFields pvtFieldsRow, pvtFieldsCol
pvtTable.PivotFields("Date").Orientation = xlDataField
End Sub
Note:
In some (newer?) versions of Excel, the line
Set pvtCache = ActiveWorkbook.PivotCaches.Add(xlDatabase, rngData.Address(True, True, 1, True))
can be changed to
Set pvtCache = ActiveWorkbook.PivotCaches.Add(xlDatabase, rngData)
Or maybe my old version of Excel is just bad. I don't know.
I also posted a .vbs solution here:
http://gallery.technet.microsoft.com/ScriptCenter/en-us/dde1e5e2-f5f6-4053-84fb-b820f01f1fdf