Problem sorting in Excel 2000 vs. 2003
I have a macro that sorts the following code fine in Excel 2003 but stops the
macro in Excel 2000. Here is the code that is not working in Excel 2000. Any suggestions are appreciated: Range("A5:S5000").Select Selection.Sort Key1:=Range("A5"), Order1:=xlAscending, Header:=xlNo, _ OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom, _ DataOption1:=xlSortNormal -- David P. |
Problem sorting in Excel 2000 vs. 2003
DataOption1:=xlSortNormal
Was added in xl2002. Delete it from your code and you should be ok (don't forget the preceding comma and underscore, too). David P. wrote: I have a macro that sorts the following code fine in Excel 2003 but stops the macro in Excel 2000. Here is the code that is not working in Excel 2000. Any suggestions are appreciated: Range("A5:S5000").Select Selection.Sort Key1:=Range("A5"), Order1:=xlAscending, Header:=xlNo, _ OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom, _ DataOption1:=xlSortNormal -- David P. -- Dave Peterson |
Problem sorting in Excel 2000 vs. 2003
That's fantastic Dave. Thanks so much.
-- David P. "Dave Peterson" wrote: DataOption1:=xlSortNormal Was added in xl2002. Delete it from your code and you should be ok (don't forget the preceding comma and underscore, too). David P. wrote: I have a macro that sorts the following code fine in Excel 2003 but stops the macro in Excel 2000. Here is the code that is not working in Excel 2000. Any suggestions are appreciated: Range("A5:S5000").Select Selection.Sort Key1:=Range("A5"), Order1:=xlAscending, Header:=xlNo, _ OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom, _ DataOption1:=xlSortNormal -- David P. -- Dave Peterson |
Problem sorting in Excel 2000 vs. 2003
We "David P.'s" have to stick together!
David P. wrote: That's fantastic Dave. Thanks so much. -- David P. "Dave Peterson" wrote: DataOption1:=xlSortNormal Was added in xl2002. Delete it from your code and you should be ok (don't forget the preceding comma and underscore, too). David P. wrote: I have a macro that sorts the following code fine in Excel 2003 but stops the macro in Excel 2000. Here is the code that is not working in Excel 2000. Any suggestions are appreciated: Range("A5:S5000").Select Selection.Sort Key1:=Range("A5"), Order1:=xlAscending, Header:=xlNo, _ OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom, _ DataOption1:=xlSortNormal -- David P. -- Dave Peterson -- Dave Peterson |
All times are GMT +1. The time now is 12:57 PM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com