Transpose 2nd line, 3 cells, to first open column - thend elete all 2nd blank rows

Wizerd

New Member
Joined
Aug 11, 2017
Messages
28
All,

I have a sheet that contains content in the first/odd rows from A1 to M1. The second/even rows have content from A2 to C2. I wish to transpose A2 > N1, B2 > O1 and C2 >P1.

Any help would be appreciated.
[TABLE="width: 1195"]
<colgroup><col><col><col><col><col><col><col><col><col><col><col><col><col></colgroup><tbody>[TR]
[TD]1[/TD]
[TD]1BD1209715 [/TD]
[TD]180309[/TD]
[TD]14:37[/TD]
[TD]181156095[/TD]
[TD]162012[/TD]
[TD]P[/TD]
[TD]84[/TD]
[TD] 6GC69[/TD]
[TD][/TD]
[TD] GAN[/TD]
[TD]12[/TD]
[TD]6[/TD]
[/TR]
[TR]
[TD]POST90SP[/TD]
[TD]*DVT[/TD]
[TD]GSIP[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]2[/TD]
[TD]1BP1242049 [/TD]
[TD]180301[/TD]
[TD]08:42[/TD]
[TD]181154414[/TD]
[TD]160466[/TD]
[TD]P[/TD]
[TD]84[/TD]
[TD] 1GZ69[/TD]
[TD][/TD]
[TD] GAN[/TD]
[TD]13[/TD]
[TD]14[/TD]
[/TR]
[TR]
[TD]POST90SP[/TD]
[TD]*DVT[/TD]
[TD]GSIP[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]3[/TD]
[TD]1BP1242423 [/TD]
[TD]180302[/TD]
[TD]12:00[/TD]
[TD]181154842[/TD]
[TD]160797[/TD]
[TD]P[/TD]
[TD]84[/TD]
[TD] 6GC69[/TD]
[TD][/TD]
[TD] GBA[/TD]
[TD]12[/TD]
[TD]13[/TD]
[/TR]
[TR]
[TD]POST90SP[/TD]
[TD]*DVT[/TD]
[TD]GSIP[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
 

Excel Facts

Format cells as time
Select range and press Ctrl+Shift+2 to format cells as time. (Shift 2 is the @ sign).
then do you want the empty rows deleting. also what is the very first line, is it 1 or 2 dont want to run on the wrong line.
 
Upvote 0
Code:
Dim i As Long
Dim lastrow As Long


    lastrow = ActiveSheet.Cells(Rows.Count, 1).End(xlUp).Row
    
    For i = lastrow To 2 Step -1
        If Cells(i, 4) = "" Then
            Cells(i, 1).Resize(1, 3).Copy Cells(i - 1, 14)
            Cells(i, 1).EntireRow.Delete
        End If
    Next i
        
End Sub
 
Upvote 0
Solution
‘1’ is in A1. And yes’ after the transpose I need the blank line deleted. Thanks for the quick responses.
 
Upvote 0
Works great. If I wanted to start this transpose at A6 instead of A1 (different worksheet...same principle)
 
Upvote 0
yes, it runs backwards though so where I say For i = lastrow To 2 Step -1 you change the 2 to what ever row number you want to finish on working from bottom to top
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,179
Members
453,021
Latest member
Justyna P

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