Flip Flop

abacon1960

Board Regular
Joined
Jul 28, 2014
Messages
54
I have a set of data listed from AZ2 all the way to AZ556.

EXAMPLE.

1675
4578
5689
1256
4456
5568
etc.

I want to flip the data so the column will now read. This will allow me to align it with the correct dates that are set in stone on the spreadsheet. The dates are set in reverse order of the data I am importing. The dates need to remain as they ARE.

5568
4456
1256
5689
4578
1675

Is this possible?
 

Excel Facts

Test for Multiple Conditions in IF?
Use AND(test, test, test, test) or OR(test, test, test, ...) as the logical_test argument of IF.
Does this do what you want...

Code:
Sub Flip()


    Dim fLop, i As Long, r As Long
    
    Application.ScreenUpdating = False
    r = 1
    fLop = Range("AZ2:AZ556")
    For i = 556 To 2 Step -1
        Cells(i, 52) = fLop(r, 1)
        r = r + 1
    Next
    Application.ScreenUpdating = True
    
End Sub
 
Last edited:
Upvote 0
alternative

PowerQuery

Code:
[SIZE=1]let
    Source = Excel.CurrentWorkbook(){[Name="Table16"]}[Content],
    #"Reversed Rows" = Table.ReverseRows(Source)
in
    #"Reversed Rows"[/SIZE]
 
Upvote 0
Enter into BA2 (any parallel column) and copy down through BA556:

=INDEX($AZ$2:$AZ$556, ROWS($AZ$2:$AZ$556)-ROWS($AZ$2:AZ2)+1)

The key thing that makes this work is the relative reference highlighted in red.
 
Last edited:
Upvote 0

Forum statistics

Threads
1,223,227
Messages
6,170,848
Members
452,361
Latest member
d3ad3y3

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top