Sort based on column values then repeat

jrf1111

New Member
Joined
Feb 24, 2016
Messages
4
Hi all, I have a worksheet that looks something like this:
Person#Stuff #Data
Person11Person1 stuff 1
Person12Person1 stuff 2
Person22Person2 stuff 2
Person24Person2 stuff 4
Person23Person2 stuff 3
Person21Person2 stuff 1
Person32Person3 stuff 2
Person31Person3 stuff 1

<tbody>
</tbody>

For some reason Excel won't sort first by Col A (Person #) then by Col B (Stuff #) so it will look like this:
Person#Stuff #Data
Person11Person1 stuff 1
Person12Person1 stuff 2
Person21Person2 stuff 1
Person22Person2 stuff 2
Person23Person2 stuff 3
Person24Person2 stuff 4
Person31Person3 stuff 1
Person32Person3 stuff 2

<tbody>
</tbody>


Is there someway to do this in VBA? Thanks in advance.
 

Excel Facts

Which lookup functions find a value equal or greater than the lookup value?
MATCH uses -1 to find larger value (lookup table must be sorted ZA). XLOOKUP uses 1 to find values greater and does not need to be sorted.
just try sorting Column B smallest to largest THAN sort Column A A to Z
 
Upvote 0
It gave me something like this
Person#Stuff#
Person11
Person21
Person31
Person12
Person22
Person32
Person23
Person23

<tbody>
</tbody>
 
Upvote 0
you could try going to DATA, click on SORT...sort by...Stuff #.....add a level....then by...Person #....both sorted on values...Order....smallest to largest and A To Z
 
Upvote 0

Forum statistics

Threads
1,216,027
Messages
6,128,373
Members
449,445
Latest member
JJFabEngineering

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