I have a macro that copies cells to another sheet and puts cells in order. I need to make this marco loop until there are no more rows to copy. This macro was recorded. I'm not good at writing macro from scratch.
I can't download the XL2BB so I hope you can us my macro.
I can't download the XL2BB so I hope you can us my macro.
Code:
Sub COPY_MOC()
'
' COPY_MOC Macro
'
' Keyboard Shortcut: Ctrl+Shift+Q
'
Range("A2").Select
Sheets("Sheet1").Select
Range("B2:B5").Select
Selection.Copy
Sheets("Sheet2").Select
Range("A2").Select
Selection.PasteSpecial Paste:=xlPasteAll, Operation:=xlNone, SkipBlanks:= _
False, Transpose:=True
Range("E2").Select
Sheets("Sheet1").Select
Range("D2:D5").Select
Application.CutCopyMode = False
Selection.Copy
Sheets("Sheet2").Select
Range("E2").Select
Selection.PasteSpecial Paste:=xlPasteAll, Operation:=xlNone, SkipBlanks:= _
False, Transpose:=True
Rows("2:2").Select
Application.CutCopyMode = False
Selection.Insert Shift:=xlDown, CopyOrigin:=xlFormatFromLeftOrAbove
Range("A2").Select
Sheets("Sheet1").Select
Rows("1:5").Select
Selection.Delete Shift:=xlUp
Sheets("Sheet2").Select
Range("A2").Select
End Sub