Hello there,
i would like to ask you for a help.
Im looking for make my results from the races sorted automaticly using VBA in excel.
Criteria: Category and Sex
I have got 7 sheets, on the 1 one I have got data in 11 collums the last two collums include Category(39, 49, 50) and sex(Male, Female)
Each sheet content the racers from one category and sex (Male 39, Male 49, Male 50, Female 39, Female 49, Female 50)
I think that I have to use AdvancedFilter, but its not working. It will copy all the data to list Male 39
Sub Sorter()
ListName = ActiveSheet.Name
Sheets(ListName).Range("Tabulka[#All]").AdvancedFilter Action:=xlFilterCopy, CriteriaRange:=Sheets(ListName).Range("J1", "K1"), CopyToRange:=Sheets("Male 39").Range("A2:J2"), Unique:=True
Columns.AutoFit
End Sub
Thank you for your help
i would like to ask you for a help.
Im looking for make my results from the races sorted automaticly using VBA in excel.
Criteria: Category and Sex
I have got 7 sheets, on the 1 one I have got data in 11 collums the last two collums include Category(39, 49, 50) and sex(Male, Female)
Each sheet content the racers from one category and sex (Male 39, Male 49, Male 50, Female 39, Female 49, Female 50)
I think that I have to use AdvancedFilter, but its not working. It will copy all the data to list Male 39
Sub Sorter()
ListName = ActiveSheet.Name
Sheets(ListName).Range("Tabulka[#All]").AdvancedFilter Action:=xlFilterCopy, CriteriaRange:=Sheets(ListName).Range("J1", "K1"), CopyToRange:=Sheets("Male 39").Range("A2:J2"), Unique:=True
Columns.AutoFit
End Sub
Thank you for your help