I have got an excel spreadsheet:
First row contains a list of name, dob etc.
Second row blank
Third row - Address and data follows in that format through the document -the first spreadsheet i have has 50 lines the second has a few thousand.
I have created a macro which copies the first row into a new sheet and then another macro that copies the third row into the same sheet. The second data set is copying into column A from row 251. What im trying to do is to get the first line of the second set of data to copy into column (for instance J) of the first row so that the names tally up with the address. Does that make sense?
This is the first macro to move the first line:
Sub every3()
'
' every3 Macro
' Macro recorded 05/07/2007 by Emma Gale
'
' Keyboard Shortcut: Ctrl+e
'
Range("A1").Select
Range(Selection, Selection.End(xlToRight)).
Select
Selection.Copy
Sheets("Sheet1").Select
Range("A1").Select
ActiveSheet.Paste
Application.CutCopyMode = False
For k = 1 To 250
ActiveCell.Offset(1, 0).Range("A1").Select
Sheets("RMHC Pts 16 by 7 11 2007").Select
ActiveCell.Offset(3, 0).Range("A1").Select
Range(Selection, Selection.End(xlToRight)).
Select
Selection.Copy
Sheets("Sheet1").Select
ActiveSheet.Paste
Application.CutCopyMode = False
Next k
End Sub
This is the second to move every third line:
Sub addresss()
'
' addresss Macro
' Macro recorded 05/07/2007 by Emma Gale
'
' Keyboard Shortcut: Ctrl+q
'
ActiveCell.Offset(2, 0).Range("A1:L1").Select
Selection.Copy
Sheets("Sheet1").Select
ActiveCell.Range("A1:L1").
Select
ActiveSheet.Paste
Application.CutCopyMode = False
For k = 1 To 250
ActiveCell.Offset(1, 0).Range("A1").Select
Sheets("RMHC Pts 16 by 7 11 2007").Select
ActiveCell.Offset(3, 0).Range("A1:L1").Select
Selection.Copy
Sheets("Sheet1").Select
ActiveSheet.Paste
Application.CutCopyMode = False
Next k
End Sub
Start Free Trial