ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Sort of Data (https://www.excelbanter.com/excel-programming/295891-sort-data.html)

New Sort

Sort of Data
 
I have a list of data, that calculates totals based on the current row that you are on

I want to be able to sort this data. Can I sort the data without having to select the data. When I select the data, I loose my current row

Please advise

Thanks

Bob Flanagan

Sort of Data
 
The following illustrates sorting a range without selecting it:

With Range("anyrange")
.Sort Key1:=.Cells(1), Order1:=xlAscending, Header:=xlYes, _
OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom
End With

Bob Flanagan
Macro Systems
http://www.add-ins.com
Productivity add-ins and downloadable books on VB macros for Excel

"New Sort" wrote in message
...
I have a list of data, that calculates totals based on the current row

that you are on.

I want to be able to sort this data. Can I sort the data without having

to select the data. When I select the data, I loose my current row.

Please advise.

Thanks





All times are GMT +1. The time now is 12:16 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com