Solved

Sort data by Date based on 4 column worksheet (Excel 2003)

Posted on 2011-03-04
3
288 Views
Last Modified: 2012-05-11
Hi

I have a worksheet in Excel 2003 that contains about 400 rows, (i have pasted 2 rowns below)

Colum 4 contains a date, i would like all data sorted by date order based upon this row, i was playing around myself however i managed to get column 4 in date order however colums 1 -3  never changed order so meant all my data was out of sync, can anybody tell me how to do it

Thanks

Full Path                    Size                 Allocated            Last Change    

E:\Users\GriffithsD\      14969.5 MB      9414.4 MB      03/03/2011            
E:\Users\EllisD\       7806.9 MB      5838.3 MB      04/03/2011                        
0
Comment
Question by:ncomper
3 Comments
 
LVL 22

Accepted Solution

by:
spattewar earned 500 total points
ID: 35037325
Select your entire data set starting from column 1 till you last column. then go to menu Data--Sort. Excel will automatically assume your first row of the data set as column header, if not then check the check box that says so. Select your date column in the sort by box and select asc or desc. This should sort your entire data.
0
 
LVL 17

Expert Comment

by:gtgloner
ID: 35037417
Here is some VBA code if you prefer to do it that way:
Sub sortdata()

    Columns("A:D").Select
    Selection.Sort Key1:=Range("D2"), Order1:=xlAscending, Header:=xlGuess, _
        OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom, _
        DataOption1:=xlSortNormal
    Range("A1").Select
    
End Sub

Open in new window

0
 
LVL 5

Author Comment

by:ncomper
ID: 35037436
Thanks all, doing it via data-sort worked perfect

0

Featured Post

DevOps Toolchain Recommendations

Read this Gartner Research Note and discover how your IT organization can automate and optimize DevOps processes using a toolchain architecture.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Outlook Free & Paid Tools
Excel can be a tricky bit of software to get your head around. Whilst you’ll be able to eventually get to grips with the basic understanding of how to get by, there are a few Excel tips that not everybody will even know about let alone know how to d…
This Micro Tutorial demonstrate the bugs in Microsoft Excel for Mac with Pivot Charts.
This Micro Tutorial will demonstrate in Google Sheets how to use the HYPERLINK function to create live links inside your spreadsheet.

832 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question