![]() |
how do I sort multiple rows in excel
I have a spreadsheet with 7 columns wide with a large number of rows and I
need to sort the data in the rows. I can do it for each individual row but, this time consuming and could do with knowing if there is any way to sort a couple of hundred rows. |
how do I sort multiple rows in excel
jsmith,
Select all your cells, then run a macro like this, assuming you want each row to be sorted on its own.... HTH, Bernie MS Excel MVP Sub TryNow() Dim myRow As Range For Each myRow In Selection.Rows myRow.Sort myRow.Cells(1), xlDescending, header:=xlNo, Orientation:=xlSortRows Next myRow End Sub "jsmith@nisltd" wrote in message ... I have a spreadsheet with 7 columns wide with a large number of rows and I need to sort the data in the rows. I can do it for each individual row but, this time consuming and could do with knowing if there is any way to sort a couple of hundred rows. |
how do I sort multiple rows in excel
If you have fewer than 255 rows, select everything, copy, paste special,
transpose, to turn your rows into columns. "jsmith@nisltd" wrote: I have a spreadsheet with 7 columns wide with a large number of rows and I need to sort the data in the rows. I can do it for each individual row but, this time consuming and could do with knowing if there is any way to sort a couple of hundred rows. |
how do I sort multiple rows in excel
I vote for Bernie's suggestion.
"Bernie Deitrick" wrote: jsmith, Select all your cells, then run a macro like this, assuming you want each row to be sorted on its own.... HTH, Bernie MS Excel MVP Sub TryNow() Dim myRow As Range For Each myRow In Selection.Rows myRow.Sort myRow.Cells(1), xlDescending, header:=xlNo, Orientation:=xlSortRows Next myRow End Sub "jsmith@nisltd" wrote in message ... I have a spreadsheet with 7 columns wide with a large number of rows and I need to sort the data in the rows. I can do it for each individual row but, this time consuming and could do with knowing if there is any way to sort a couple of hundred rows. |
All times are GMT +1. The time now is 08:18 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com