dim startDatum as Date dim endDatum as Date startDatum="4.1.2015." endDatum="9.1.2015." Dim rang as Range Range("F1").Select Set rang = Range(Selection, Selection.End(xlToRight)) dim imeRed as integer imeRed=Application.WorksheetFunction.Match("luka", Range("E:E"), 0) dim redIspis as Integer redIspis=0 dim kolonaIspis as Integer kolonaIspis=0 For red = 1 To rang.Rows.Count For kolona = 1 To rang.Columns.Count If rang.Cells(red, kolona).Value >= startDatum And rng.Cells(red, kolona).Value <= endDatum Then redIspis = redIspis + 1 If kolonaIspis = 0 Then kolonaIspis = rang.Row - 1 strVar = Cells(imeRed, kolona + 2).Value Cells(redIspis, 1) = rang.Cells(red, kolona).Value Cells(redIspis, 2) = Cells(imeRed, kolona + 2).Value End If Next kolona Next red