ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Sorting range multiple areas (https://www.excelbanter.com/excel-programming/306737-re-sorting-range-multiple-areas.html)

Dave Peterson[_3_]

Sorting range multiple areas
 
See one more reply at your other post.

VJ wrote:

Hi

I have a range which could be of different area selections.

For example rng1 address could be $A$37:$D$38 or $A$25:$D$26,$A$43:$D$47 or

$A$48:$D$49,$A$57:$D$57,$A$63:$D$63.

I gets the error when there are multiple areas such as $A$25:$D$26,$A$43:$D$47
but its works fine where are only one area such as $A$25:$D$26.
The error msg I get "The command you
chose cannot be performed with multiple selection. Select a single range and
click the command again"

Can somebody help me out to write a generic VBA macro to sort the range
according to column 1?

Help would really be appreciated.

In my previous posting, I didnt get my answer but by mistake i pressed Yes
btn, Sorry for that.

Thanks and regards,


--

Dave Peterson



All times are GMT +1. The time now is 11:56 PM.

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