Copy from Column to Column

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I need help in copying data from column to column
I going to give an example.
Example, Worksheet 1, cell A1= bob, cell A2 = mike, cell A3= jim
I want the macro to goto Worksheet 2 and find the first column where the cells a1 through a3 are empty; the cells below a3 may have data in them

Then I want the macro to copy the contents of Worksheet1, a1:a3 into the empty cells (A1:A3) in the first selected empty column in Worksheet 2

The next time I use the macro, there is different data in worksheet 1, in cells a1:a3. The macro will then copy these new string values into the next empty column in worksheet 2

I appreciate any help someone can offer
Mike
 
This sounds awful familiar - did you post this before.

for each cell in Worksheets("Sheet2").Range("A1:IV1")
if application.countA(cell.Resize(3,1)) = 0 then
cell.Resize(3,1).Value = Worksheets("Sheet1").Range("A1:A3").Value
exit for
end if
Next

--
Regards,
Tom Ogilvy


mike said:
I need help in copying data from column to column.
I going to give an example.
Example, Worksheet 1, cell A1= bob, cell A2 = mike, cell A3= jim.
I want the macro to goto Worksheet 2 and find the first column where the
cells a1 through a3 are empty; the cells below a3 may have data in them.
Then I want the macro to copy the contents of Worksheet1, a1:a3 into the
empty cells (A1:A3) in the first selected empty column in Worksheet 2.
The next time I use the macro, there is different data in worksheet 1, in
cells a1:a3. The macro will then copy these new string values into the next
empty column in worksheet 2.
 
Yes Tom, I had asked for help with this before and could not get the program subroutine to work.
What you sent to me now works perfectly, just wanted to thank you.

Could you suggest a reference book that would explain how and why to use such
functions as "resize", "destination","xlup" and so forth. My reference manuals
do not show these functions.

thanks
Mike
 
Back
Top