ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Moving multiple row cells into one row (https://www.excelbanter.com/excel-programming/287029-moving-multiple-row-cells-into-one-row.html)

ser

Moving multiple row cells into one row
 
Hello,

I am new to Excel formulas and just need to know how to move the
contents of multiple rows into one row without needing to know (hard
code) the end cell value. (this could be C1 or it could be EE1 or....)

Example:

ABC
DEF
GHI

into ...

ABC DEF GHI (contents of multiple rows into one row)

Is there a simple formula syntax value for range for this type of thing
in the options in menu bar for "text to columns"?

Thank you.

- S



---
Message posted from
http://www.ExcelForum.com/


Colo[_71_]

Moving multiple row cells into one row
 
Why don't you use PasteSpecial Transpose when you paste?
Or coding something like this.


Code:
--------------------

Sub Test()
Dim Target As Range
On Error Resume Next
Set Target = Application.InputBox("Select Data", Type:=8)
If Target Is Nothing Then Exit Sub
Target.Copy
Selection.PasteSpecial Transpose:=True
Application.CutCopyMode = False
End Sub

--------------------



---
Message posted from http://www.ExcelForum.com/



All times are GMT +1. The time now is 02:07 PM.

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