P
Patrick Simonds
I want to sort all worksheets without selecting them. I was attempting to
alter some code I got from Norman Jones which allowed me to perform other
functions with out actually selecting the worksheet, but it only seems to
sort the active worksheet. What am I missing?
Dim SH As Worksheet
For Each SH In ActiveWorkbook.Worksheets
Range("A3:h1301").Select
Selection.Sort Key1:=Range("A4"), Order1:=xlAscending, Header:=xlGuess,
_
OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom, _
DataOption1:=xlSortNormal
Next SH
alter some code I got from Norman Jones which allowed me to perform other
functions with out actually selecting the worksheet, but it only seems to
sort the active worksheet. What am I missing?
Dim SH As Worksheet
For Each SH In ActiveWorkbook.Worksheets
Range("A3:h1301").Select
Selection.Sort Key1:=Range("A4"), Order1:=xlAscending, Header:=xlGuess,
_
OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom, _
DataOption1:=xlSortNormal
Next SH