I am having a problem. I have two sets of data that need to be sorted using a specified list. I am using custom list to add the correct list. However when I apply them to the data they do not "take". I have the folloing :
Sheets("Raw Data").Select
Range("C1:L1").Select
Application.AddCustomList ListArray:=Range("C1:L1")
Varlist = Application.CustomListCount
Varlist = Varlist + 1
Sheets("Raw Data").Select
Range("C3").Select
Selection.Sort Key1:=Range("C3"), Order1:=xlAscending, Header:=xlGuess, _
OrderCustom:=Varlist, MatchCase:=False, Orientation:=xlLeftToRight
'Delete list
Application.DeleteCustomList (Varlist - 1)
Sheets("Raw Data").Select
Range("O1:W1").Select
Application.AddCustomList ListArray:=Range("O1:W1")
Varlist1 = Application.CustomListCount
Varlist1 = Varlist1 + 1
Sheets("Raw Data").Select
Range("O3").Select
Selection.Sort Key1:=Range("O3"), Order1:=xlAscending, Header:=xlGuess, _
OrderCustom:=Varlist1, MatchCase:=False, Orientation:=xlLeftToRight
'Delete list
Application.DeleteCustomList (Varlist1 - 1)
Sheets("Raw Data").Select
Range("C1:L1").Select
Application.AddCustomList ListArray:=Range("C1:L1")
Varlist = Application.CustomListCount
Varlist = Varlist + 1
Sheets("Raw Data").Select
Range("C3").Select
Selection.Sort Key1:=Range("C3"), Order1:=xlAscending, Header:=xlGuess, _
OrderCustom:=Varlist, MatchCase:=False, Orientation:=xlLeftToRight
'Delete list
Application.DeleteCustomList (Varlist - 1)
Sheets("Raw Data").Select
Range("O1:W1").Select
Application.AddCustomList ListArray:=Range("O1:W1")
Varlist1 = Application.CustomListCount
Varlist1 = Varlist1 + 1
Sheets("Raw Data").Select
Range("O3").Select
Selection.Sort Key1:=Range("O3"), Order1:=xlAscending, Header:=xlGuess, _
OrderCustom:=Varlist1, MatchCase:=False, Orientation:=xlLeftToRight
'Delete list
Application.DeleteCustomList (Varlist1 - 1)