Sorting

S

sammy2x

Hi,

Lets say I have a list of Sales Reps in column A, Turnover Figures in
B, Cost Value in C, Margin in D etc etc.......

I need to sort them, sometimes by Rep, some times by Margin ascending,
sometimes by Turnover Ascending etc etc.

Are there any formulas I can use to do this instead of using the sort
function EVERY TIME

Cheers Guys
 
B

broro183

Hi Sammy,

Have a look at Dave's suggested technique on Debra's site:
http://contextures.com/xlSort02.html

btw, there is a very similar thread to yours which is recent & where I
saw this link - I just can't find it at the moment.

Hth,
Rob Brockett
NZ
Always learning & the best way to learn is to exxperience...
 
D

Don Guillett

right click sheet tab>view code>insert this>name your range sortrange>save.
Now double click anywhere in the desired column to sort by that column.

Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Excel.Range, Cancel
As Boolean)
mycol = ActiveCell.Column
[sortrange].Sort Key1:=Cells(1, mycol), Order1:=xlAscending,
Orientation:=xlTopToBottom
End Sub
 
Top