I have two very long columns of data. I would like to flip them. For example, there are 6028 lines of data. I would like to see data on line 6028 on line 1 and data from line 6027 on line 2, so on and so forth. Can this be done?
Thanks
I have two very long columns of data. I would like to flip them. For example, there are 6028 lines of data. I would like to see data on line 6028 on line 1 and data from line 6027 on line 2, so on and so forth. Can this be done?
Thanks
Have you tried numbering a new column 6028, 6027, etc., then sorting it?
Would you like to say thanks? Please click the: " Add Reputation" button, on the grey bar below the post.
Hi
Try the following code.
This is for 50000 lines and two columns, just substitute your values appropriately.Sub Macro1() Application.ScreenUpdating = False Let Cells(1, 1).Value = 1 Let Cells(2, 1).Value = 2 Set SourceRange = Range("A1:A2") Set fillRange = Range("A1:A50000") SourceRange.AutoFill Destination:=fillRange Range("a1:c50000").Sort Key1:=Range("a1"), Order1:=xlDescending, Header:=xlGuess, _ OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom Range("a1:a50000").ClearContents Application.ScreenUpdating = True End Sub
Regards
Jeff
thanks, the numbering of columns worked easily.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks