ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Copy multiple cells to one cell (https://www.excelbanter.com/excel-discussion-misc-queries/170758-copy-multiple-cells-one-cell.html)

Tigerxxx

Copy multiple cells to one cell
 
How can I copy data in multiple cells into one cell one after the other?
Example-
Cells A1=3, B1=4, C1=5......Y1=25, Z1=26
I want to copy the data in cells A1,B1 through Z1 into one single cell A2 as
3,4 ,5....26.

Please advise.

Marcelo

Copy multiple cells to one cell
 
Try to concatenate

=a1&", "b1"& etc

hth
--
regards from Brazil
Thanks in advance for your feedback.
Marcelo



"Tigerxxx" escreveu:

How can I copy data in multiple cells into one cell one after the other?
Example-
Cells A1=3, B1=4, C1=5......Y1=25, Z1=26
I want to copy the data in cells A1,B1 through Z1 into one single cell A2 as
3,4 ,5....26.

Please advise.


Tigerxxx

Copy multiple cells to one cell
 
Thanks for your input Marcelo.

As I understand concatenate can only work for five cells at a time. I was
looking for some other convenient way for higher number of cells.

Thank you

"Marcelo" wrote:

Try to concatenate

=a1&", "b1"& etc

hth
--
regards from Brazil
Thanks in advance for your feedback.
Marcelo



"Tigerxxx" escreveu:

How can I copy data in multiple cells into one cell one after the other?
Example-
Cells A1=3, B1=4, C1=5......Y1=25, Z1=26
I want to copy the data in cells A1,B1 through Z1 into one single cell A2 as
3,4 ,5....26.

Please advise.


David Biddulph[_2_]

Copy multiple cells to one cell
 
Which 2 cells are you omitting between C1 and Y1?
--
David Biddulph

"Tigerxxx" wrote in message
...
How can I copy data in multiple cells into one cell one after the other?
Example-
Cells A1=3, B1=4, C1=5......Y1=25, Z1=26
I want to copy the data in cells A1,B1 through Z1 into one single cell A2
as
3,4 ,5....26.

Please advise.




David Biddulph[_2_]

Copy multiple cells to one cell
 
You understand wrongly. What made you think that?
--
David Biddulph

"Tigerxxx" wrote in message
...
Thanks for your input Marcelo.

As I understand concatenate can only work for five cells at a time. I was
looking for some other convenient way for higher number of cells.

Thank you

"Marcelo" wrote:

Try to concatenate

=a1&", "b1"& etc

hth
--
regards from Brazil
Thanks in advance for your feedback.
Marcelo



"Tigerxxx" escreveu:

How can I copy data in multiple cells into one cell one after the
other?
Example-
Cells A1=3, B1=4, C1=5......Y1=25, Z1=26
I want to copy the data in cells A1,B1 through Z1 into one single cell
A2 as
3,4 ,5....26.

Please advise.




Tigerxxx

Copy multiple cells to one cell
 
Hi David,

I am sorry...let me rephrase the example-
Example-
Cells A1=1, B1=2, C1=3......Y1=25, Z1=26
I want to copy the data in cells A1,B1 through Z1 into one single cell A2
i.e. I want to copy 26 cells into one single cell.

Please advise. Thank you.

"David Biddulph" wrote:

Which 2 cells are you omitting between C1 and Y1?
--
David Biddulph

"Tigerxxx" wrote in message
...
How can I copy data in multiple cells into one cell one after the other?
Example-
Cells A1=3, B1=4, C1=5......Y1=25, Z1=26
I want to copy the data in cells A1,B1 through Z1 into one single cell A2
as
3,4 ,5....26.

Please advise.





David Biddulph[_2_]

Copy multiple cells to one cell
 
The answer is to use concatenation, as previously explained.
=A1&", "&B1&", "&C1&", "&D1&", "&E1&", "&F1&", "&G1&", "&H1&", "&I1&",
"&J1&", "&K1&", "&L1&", "&M1&", "&N1&", "&O1&", "&P1&", "&Q1&", "&R1&",
"&S1&", "&T1&", "&U1&", "&V1&", "&W1&", "&X1&", "&Y1&", "&Z1
--
David Biddulph

"Tigerxxx" wrote in message
...
Hi David,

I am sorry...let me rephrase the example-
Example-
Cells A1=1, B1=2, C1=3......Y1=25, Z1=26
I want to copy the data in cells A1,B1 through Z1 into one single cell A2
i.e. I want to copy 26 cells into one single cell.

Please advise. Thank you.

"David Biddulph" wrote:

Which 2 cells are you omitting between C1 and Y1?
--
David Biddulph

"Tigerxxx" wrote in message
...
How can I copy data in multiple cells into one cell one after the
other?
Example-
Cells A1=3, B1=4, C1=5......Y1=25, Z1=26
I want to copy the data in cells A1,B1 through Z1 into one single cell
A2
as
3,4 ,5....26.

Please advise.







Max

Copy multiple cells to one cell
 
"Tigerxxx" wrote:
Cells A1=1, B1=2, C1=3......Y1=25, Z1=26
I want to copy the data in cells A1,B1 through Z1 into one single cell A2
i.e. I want to copy 26 cells into one single cell.


Another option - try this sub by Gord Dibben

Sub ConCat_Cells()
'Gord Dibben .misc
Dim x As Range
Dim y As Range
Dim z As Range
Dim w As String
Dim sbuf As String
On Error GoTo endit
w = InputBox("Enter the Type of De-limiter Desired")
Set z = Application.InputBox("Select Destination Cell", _
"Destination Cell", , , , , , 8)
Application.SendKeys "+{F8}"
Set x = Application.InputBox _
("Select Cells...Contiguous or Non-Contiguous", _
"Cells Selection", , , , , , 8)
For Each y In x
If Len(y.Text) 0 Then sbuf = sbuf & y.Text & w
Next
z = Left(sbuf, Len(sbuf) - 1)
Exit Sub
endit:
MsgBox "Nothing Selected. Please try again."
End Sub

--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---

Tigerxxx

Copy multiple cells to one cell
 
Thanks a lot for your help guys!

Hi Max,
The macro will ber very helpful!

Thanks!

"Max" wrote:

"Tigerxxx" wrote:
Cells A1=1, B1=2, C1=3......Y1=25, Z1=26
I want to copy the data in cells A1,B1 through Z1 into one single cell A2
i.e. I want to copy 26 cells into one single cell.


Another option - try this sub by Gord Dibben

Sub ConCat_Cells()
'Gord Dibben .misc
Dim x As Range
Dim y As Range
Dim z As Range
Dim w As String
Dim sbuf As String
On Error GoTo endit
w = InputBox("Enter the Type of De-limiter Desired")
Set z = Application.InputBox("Select Destination Cell", _
"Destination Cell", , , , , , 8)
Application.SendKeys "+{F8}"
Set x = Application.InputBox _
("Select Cells...Contiguous or Non-Contiguous", _
"Cells Selection", , , , , , 8)
For Each y In x
If Len(y.Text) 0 Then sbuf = sbuf & y.Text & w
Next
z = Left(sbuf, Len(sbuf) - 1)
Exit Sub
endit:
MsgBox "Nothing Selected. Please try again."
End Sub

--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---


Max

Copy multiple cells to one cell
 
Welcome, think Gord would be pleased to hear that as well !
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"Tigerxxx" wrote in message
...
Thanks a lot for your help guys!

Hi Max,
The macro will be very helpful!

Thanks!





All times are GMT +1. The time now is 01:24 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com