Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default sort 2 columns with "large"

I have been told I can sort column A with the "large" command, and have associated names in column B sort the same way if I select both columns together and then sort by "large",- but I don't understand how to do this. Where do I put the command? When do I select the 2 columns? Exactly what does the command look like? e.g. If ages 10, 20, and 15 are placed in cells A1, A2, and A3, and names X, Y, and Z are in cells B1, B2, and B3; where do I put the command and what does it look like, to sort column A in descending order and keep the same names associated with the ages in the column beside it? Thank you for your help. Dan
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,092
Default sort 2 columns with "large"

To do this manually, select all the data you want sorted. On the menu click
Data/Sort. Choose the column to want all the data to sort by (column A for
age) and select Descending if you want the oldest age listed first.

"Dan Kraemer" wrote in message
...
I have been told I can sort column A with the "large" command, and have

associated names in column B sort the same way if I select both columns
together and then sort by "large",- but I don't understand how to do this.
Where do I put the command? When do I select the 2 columns? Exactly what
does the command look like? e.g. If ages 10, 20, and 15 are placed in cells
A1, A2, and A3, and names X, Y, and Z are in cells B1, B2, and B3; where do
I put the command and what does it look like, to sort column A in descending
order and keep the same names associated with the ages in the column beside
it? Thank you for your help. Dan


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,092
Default sort 2 columns with "large"

If you want VBCode to do this, try this:

Sub SortBy_Oldest()

Range("A1").Select
Selection.CurrentRegion.Select
Selection.Sort Key1:=Range("A1"), Order1:=xlDescending, Header:=xlGuess,
_
OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom
End Sub

Mike


"Dan Kraemer" wrote in message
...
I have been told I can sort column A with the "large" command, and have

associated names in column B sort the same way if I select both columns
together and then sort by "large",- but I don't understand how to do this.
Where do I put the command? When do I select the 2 columns? Exactly what
does the command look like? e.g. If ages 10, 20, and 15 are placed in cells
A1, A2, and A3, and names X, Y, and Z are in cells B1, B2, and B3; where do
I put the command and what does it look like, to sort column A in descending
order and keep the same names associated with the ages in the column beside
it? Thank you for your help. Dan


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
sort 2 column in the same time "" as dictionary "" Mahmoud Mustafa Excel Worksheet Functions 0 May 1st 10 01:53 PM
Missing sort ascending or descending when go into "data" "sort"? Jason Excel Discussion (Misc queries) 5 September 17th 08 11:57 PM
Excel - Golf - how to display "-2" as "2 Under" or "4"as "+4" or "4 Over" in a calculation cell Steve Kay Excel Discussion (Misc queries) 2 August 8th 08 01:54 AM
pictures to work with "data" "sort" option arad Excel Discussion (Misc queries) 1 April 18th 06 09:15 PM
Utility to "clean up" or "defrag" large Excel file Sabrina Excel Discussion (Misc queries) 3 January 12th 06 09:57 PM


All times are GMT +1. The time now is 07:09 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"