Changing the sort order

liampog

Active Member
Joined
Aug 3, 2010
Messages
316
Office Version
  1. 365
  2. 2016
Platform
  1. Windows
Hi there

Currently I have a macro set up that sorts a range.

It sorts numbers first in ascending order and then text comes at the bottom of the sorted range.

Is there any way of reversing this so that text appears first and then numeric values in ascending order below?

THanks,
Liam
 

Excel Facts

What did Pito Salas invent?
Pito Salas, working for Lotus, popularized what would become to be pivot tables. It was released as Lotus Improv in 1989.
Just thinking out loud, have you considered using a helper column, example, if your data of numbers and text is in column A, then in the next available column of your table you could enter and copy down:
=ISTEXT(A1)

Then, Copy and paste special for values that helper column, and sort the table with the primary field being that column, for descending order (because TRUE for text would sort above FALSE). Then for the secondary column A, sort in ascending order and that might all get you what you want. Finish up by deleting the helper column.
 
Upvote 0

Forum statistics

Threads
1,225,051
Messages
6,182,572
Members
453,126
Latest member
NigelExcel

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top