schuyler
asked on
concatenate 2 columns down 100 rows
data looks like this
Col1 Col2
2345 Sore throat
1123Q Bad cough
etc down 100 rows
Would like result to look like this (in one cell)
2345-Sore throat; 1123Q-Bad Cough; etc
Thanks in advance for your prompt response!
Schuyler
Col1 Col2
2345 Sore throat
1123Q Bad cough
etc down 100 rows
Would like result to look like this (in one cell)
2345-Sore throat; 1123Q-Bad Cough; etc
Thanks in advance for your prompt response!
Schuyler
assume data in A1 & B1 in C1 put =A1 & "-" & B1
use enter to finish editing.
move the mouse to the bottom right hand corner of the cell the cursor will change to a narrow cross.
Either drag down to row 100, or if you have data that stops at row 100 just double click, the formula will autofill down until it comes to a break in the data.
You could of course use both techniques, use the double click then goto the bottom cell (by double clicking anywhere else on the bottom edge) and then just drag down the last few rows :)
use enter to finish editing.
move the mouse to the bottom right hand corner of the cell the cursor will change to a narrow cross.
Either drag down to row 100, or if you have data that stops at row 100 just double click, the formula will autofill down until it comes to a break in the data.
You could of course use both techniques, use the double click then goto the bottom cell (by double clicking anywhere else on the bottom edge) and then just drag down the last few rows :)
ASKER
Thanks...but I know how to do that, what I need to do is have all the data in one cell, I need to transfer it to another sheet as a list of data
Patrick,
in the excel file, in a cell I put =Concat(A19:B176,B2:C176) but nothing is happening (yes I put the function in a module)
Thanks
Patrick,
in the excel file, in a cell I put =Concat(A19:B176,B2:C176) but nothing is happening (yes I put the function in a module)
Thanks
schuyler,
Please post your file.
Patrick
Please post your file.
Patrick
Schuyler, you could also look at this previous question and see if the same solution works for you,
regards
regards
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Patrick,
I can't send the file but if you look at what example that royhsiao posted above, that's what the file looks like, even column C...if we could use that column using an ";" btwn each set of values that would work as well.
thanks
I can't send the file but if you look at what example that royhsiao posted above, that's what the file looks like, even column C...if we could use that column using an ";" btwn each set of values that would work as well.
thanks
Did you tryed my code?
ASKER
jppinto
Where do I put the call? I can step thru your code jppinto but where is it on the spreadsheet...sorry its been a while since I needed to code in excel....appreciate everyone's help
Where do I put the call? I can step thru your code jppinto but where is it on the spreadsheet...sorry its been a while since I needed to code in excel....appreciate everyone's help
Alt+F11 takes you to the VBA editor. You can place your code into your file and the click on the Run button (or press F5) to run your code on your sheet.
jppinto
Capture.JPG
jppinto
Capture.JPG
ASKER
thanks so much!
patrick I know your code was similar but i couldn't get it to work and jppinto's did...appreciate your efforts!!
Schuyler
patrick I know your code was similar but i couldn't get it to work and jppinto's did...appreciate your efforts!!
Schuyler
You would need VBA code for that.
For example:
Open in new window
Assuming your data are in, say, A2:B100...
=Concat(A2:A100,B2:B100)
Patrick