ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   in order of columns (https://www.excelbanter.com/excel-discussion-misc-queries/84077-order-columns.html)

ceemo

in order of columns
 

I would like to orrange the names in order of sales then days work then
priority


name priority days work sales
bob 1 1 3
pete 3 1 3
jane 2 2 5
jill 5 3 5
terry 4 1 4

the results would be

Jill
Jane
Terry
Pete
Bob


Ive been given some tips of the rank function but havnt managed to work
out how best to use it for my purpose.


--
ceemo
------------------------------------------------------------------------
ceemo's Profile: http://www.excelforum.com/member.php...o&userid=10650
View this thread: http://www.excelforum.com/showthread...hreadid=534349


Don Guillett

in order of columns
 
Won't SORT work for you?
A recorded macro

Sub Macro4()
'
' Macro4 Macro
' Macro recorded 4/19/2006 by Don Guillett
'

'
Range("A2:D7").Select
Selection.Sort Key1:=Range("D3"), Order1:=xlDescending,
Key2:=Range("C3") _
, Order2:=xlDescending, Key3:=Range("B3"), Order3:=xlDescending,
Header _
:=xlGuess, OrderCustom:=1, MatchCase:=False,
Orientation:=xlTopToBottom _
, DataOption1:=xlSortNormal, DataOption2:=xlSortNormal,
DataOption3:= _
xlSortNormal
End Sub

--
Don Guillett
SalesAid Software

"ceemo" wrote in
message ...

I would like to orrange the names in order of sales then days work then
priority


name priority days work sales
bob 1 1 3
pete 3 1 3
jane 2 2 5
jill 5 3 5
terry 4 1 4

the results would be

Jill
Jane
Terry
Pete
Bob


Ive been given some tips of the rank function but havnt managed to work
out how best to use it for my purpose.


--
ceemo
------------------------------------------------------------------------
ceemo's Profile:
http://www.excelforum.com/member.php...o&userid=10650
View this thread: http://www.excelforum.com/showthread...hreadid=534349





All times are GMT +1. The time now is 08:53 PM.

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