Combining columns

I

iznogud

So,

the thing is I need to connect two columns into one, but in a way that it
puts one row from the first column, then a row from the second, and then
again from then first etc..
can that be done?
 
B

Bernard Liengme

Not sure what is wanted. Try this and tell if it works
=A1&B1
or
=A1&" "&B1
best wishes
 
I

iznogud

no that didn't do it, it connected it into a single column, but what I need
is to take row from one column, and put a row from the second one underneath
it, and so on..
is there a place where I could put the tables somewhere here so I can write
 
H

Harlan Grove

iznogud said:
is to take row from one column, and put a row from the second
one underneath it, and so on..
....

Name the first column Col1 and the second Col2. If they're in the same
worksheet, and the topmost cell in the result range were X5,

X5:
=INDEX((Col1,Col2),INT((ROWS(X$5:X5)+1)/2),1,2-MOD(ROWS(X$5:X5),2))

Fill X5 down as far as needed.
 
G

Gord Dibben

You may want to try this macro.

Sub columnmerge()
'original data is preserved and combine takes
'place in a new column try changing the "2" to a different number for more
columns
For i = 1 To 250 ' change to suit
ActiveSheet.Cells(i, 3) = ActiveSheet.Cells _
((i + 1 - ((i + 1) Mod 2)) / 2, ((i + 1) Mod 2) + 1)
Next i

End Sub

When done, delete the original columns if you wish.


Gord Dibben MS Excel MVP
 
Top