Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
hi everyone here is code which Merge data in multiple columns into one
http://www.mcgimpsey.com/excel/index.html#xlvbamacros i just want to do opposite of this i have data in a column and i want to put it in different columns (sequentially) data in a column is separated by an empty cell say i have data from a1 to a5 then empty cell again a7:a13 again empty cell like wise [n] number of data in "a" so i want to put a1:a5 data in c1:c5 a7:a13 data in d1:d7 etc etc i hope i wil get spport from this experts community many thanx in advance waiting 4 ur reply |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Give this a whirl.
Sub MoveData() Dim rng As Range x = 3 With Cells Set rng = .Range(.Cells(1, 1), .Cells(1, 1).End(xlDown)) Do rng.Select Selection.Copy Cells(1, x).PasteSpecial x = x + 1 rng.Offset(2, 0).Select Selection.Find("").Offset(1, 0).Activate If ActiveCell = "" Then Exit Sub End If Set rng = .Range(ActiveCell.Address, ActiveCell.End(xlDown)) Loop End With End Sub-- Best wishes, Jim " wrote: hi everyone here is code which Merge data in multiple columns into one http://www.mcgimpsey.com/excel/index.html#xlvbamacros i just want to do opposite of this i have data in a column and i want to put it in different columns (sequentially) data in a column is separated by an empty cell say i have data from a1 to a5 then empty cell again a7:a13 again empty cell like wise [n] number of data in "a" so i want to put a1:a5 data in c1:c5 a7:a13 data in d1:d7 etc etc i hope i wil get spport from this experts community many thanx in advance waiting 4 ur reply |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Nitn28,
If the values in column A are just values (not formulas): Sub Nitn28() Dim i As Integer With Range("A:A").SpecialCells(xlCellTypeConstants, 23) For i = 1 To .Areas.Count Cells(1, i + 2).Resize(.Areas(i).Cells.Count).Value = _ .Areas(i).Cells.Value Next i End With End Sub HTH, Bernie MS Excel MVP wrote in message oups.com... hi everyone here is code which Merge data in multiple columns into one http://www.mcgimpsey.com/excel/index.html#xlvbamacros i just want to do opposite of this i have data in a column and i want to put it in different columns (sequentially) data in a column is separated by an empty cell say i have data from a1 to a5 then empty cell again a7:a13 again empty cell like wise [n] number of data in "a" so i want to put a1:a5 data in c1:c5 a7:a13 data in d1:d7 etc etc i hope i wil get spport from this experts community many thanx in advance waiting 4 ur reply |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
THANKS ALOT
Mr. Bernie Deitrick & Mr. Jim Jackson for your time , effort it worked fine , Many Thanks again wishing u great time ahead with regrds nitn28 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Merging multiple columns of data into one column of data | Excel Discussion (Misc queries) | |||
Merging two columns, data in one | Excel Discussion (Misc queries) | |||
merging some data in 2 columns | Excel Discussion (Misc queries) | |||
Merging two columns of data | Excel Discussion (Misc queries) | |||
Merging duplicate data across multiple columns | Excel Programming |