copy multiple cells

  • Thread starter Thread starter B. Wassen
  • Start date Start date
B

B. Wassen

I have data in ceveral cells, for instance A1, C3, E11......
how can I create a macro wich copy these cells and paste them in another
sheet in a row?
Every time the macro runs, the data must be on another row.
First time paste on row 1
Second time paste on row 2
and so on...

Thanks for your help

Ben
 
Ben,

Here is a code snippet that copies all of the selected cells on one sheet to
Sheet2.

Dim cRows As Long, i As Long
Dim cell As Range

cRows = Worksheets("Sheet2").Cells(Rows.Count, "A").End(xlUp).Row
i = 1
For Each cell In Selection
cell.Value = Worksheets("Sheet2").Cells(cRows, i).Value
i = i + 1
Next cell
 
Back
Top