Home |
Search |
Today's Posts |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I just found the code below:
Sub oneLoveUmmmRow() Dim wsF As Worksheet, WST As Worksheet Dim rf As Range, rT As Range ' initialize Set wsF = ActiveSheet Set WST = Sheets.Add WST.Name = "Results" Set rf = wsF.Range("A1") Set rT = WST.Range("A1") ' rf loops through all the values in wf ' rt just moves across the sheet popping values until rf is done Do While Not rf.Value = "" Do While Not rf.Value = "" rT.Value = rf.Value & "," Set rT = rT.Offset(0, 1) Set rf = rf.Offset(0, 1) ' move rf one space right Loop Set rf = wsF.Range("A" & rf.Row + 1) ' move rf to the start of the next row Loop ' clean up Set rf = Nothing Set rT = Nothing Set wsF = Nothing Set WST = Nothing End Sub It did what I wanted after a small modification. Thanks to all who looked. Hopefully this helps someone else. Regards, Ryan--- -- RyGuy "ryguy7272" wrote: I am looking around for a simple macro that takes all items in a used range in a vertical column, transposes the data set, and adds a comma to the end if each item before the next item is put into the next cell to the right. Regards, Ryan--- -- RyGuy |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
how do I transpose items from another sheet? | Excel Discussion (Misc queries) | |||
transpose data from horizontal to vertical in a specific column | Excel Programming | |||
Macro for adding new items to list | Excel Programming | |||
Transpose into comma-delimited row | Excel Programming | |||
How do I transpose Comma Separated Data in each cell and delete t. | Excel Discussion (Misc queries) |