View Single Post
  #6   Report Post  
Posted to microsoft.public.excel.programming
Ryan H Ryan H is offline
external usenet poster
 
Posts: 489
Default append all instead of one

Or if you wish to select the cells you wish to append use this code below.
Option Explicit

Sub AppendCells()

Dim rng As Range

For Each rng In Selection
rng.Value = rng.Value & " " & rng.Offset(0, 1).Value
Next rng

End Sub

Hope this helps! If so, click "YES" below.
--
Cheers,
Ryan


"Maarkr" wrote:

I've got this code to append cell data to the right of the selected cell

ActiveCell.Value = ActiveCell.Value & " " & ActiveCell.Offset(0, 1).Value

THis code only works for a single selected cell... not multiple cells.
I want to be able to select the entire column A (not just a single cell in
col a) or multiple cells and have all cells in B append into A.

thanks