Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Help Transposing Data from Row To Column

I have a single column with data in it. The cells 1-4 contain Name
Address,City, Phone in that order continuous until A240. I would lik
to put the Name, Address,City, Phone accross in individual columns. I
a new sheet. I would like to use a vba macro without a loop if at al
possible.

Thank You for your help

Attachment filename: screenshot1.jpg
Download attachment: http://www.excelforum.com/attachment.php?postid=43452
--
Message posted from http://www.ExcelForum.com

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 171
Default Help Transposing Data from Row To Column

Why do you want to avoid a loop?

Alan Beban

NetWave128 < wrote:
I have a single column with data in it. The cells 1-4 contain Name,
Address,City, Phone in that order continuous until A240. I would like
to put the Name, Address,City, Phone accross in individual columns. In
a new sheet. I would like to use a vba macro without a loop if at all
possible.

Thank You for your help.

Attachment filename: screenshot1.jpg
Download attachment: http://www.excelforum.com/attachment.php?postid=434529
---
Message posted from http://www.ExcelForum.com/


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Help Transposing Data from Row To Column

I would prefer no loop because I don't know how to edit it...however if
that is the only way to do it, I probably should.

Additionally, the original data has a blank row(cell) between each set
of 4 properties. Is there anyway to to a copy.pastespecial.transpose
Skip blanks and have it correctly put the trasnposed data in multiple
rows instead of a sinlgle row as it is doing now.

thanks again


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

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Help Transposing Data from Row To Column

No, there is no magic function that recognizes you want to transpose groups
of 4/5 rows into the format you want.

You can write formulas on the new sheet then drag fill these down and they
will do what you want.

You can then copy them and do a pastespecial values to replace the formulas
with the values you retrieved.

Post back if interested in that approach.

--
Regards,
Tom Ogilvy


NetWave128 wrote in message
...
I would prefer no loop because I don't know how to edit it...however if
that is the only way to do it, I probably should.

Additionally, the original data has a blank row(cell) between each set
of 4 properties. Is there anyway to to a copy.pastespecial.transpose
Skip blanks and have it correctly put the trasnposed data in multiple
rows instead of a sinlgle row as it is doing now.

thanks again


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



  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,824
Default Help Transposing Data from Row To Column

If you were doing it manually (yech!), you'd do each area separately.

You can have a macro do the same thing.

Option Explicit
Sub testme()

Dim myRange As Range
Dim myArea As Range
Dim curWks As Worksheet
Dim newWks As Worksheet
Dim oRow As Long

Set curWks = ActiveSheet
Set newWks = Worksheets.Add

With curWks
Set myRange = Nothing
On Error Resume Next
Set myRange = .Range("a1", .Cells(.Rows.Count, "A").End(xlUp)) _
.Cells.SpecialCells(xlCellTypeConstants)
On Error GoTo 0

If myRange Is Nothing Then
MsgBox "No constants found in column A!"
Exit Sub
End If

oRow = 1
For Each myArea In myRange.Areas
myArea.Copy
newWks.Cells(oRow, "A").PasteSpecial Transpose:=True
oRow = oRow + 1
Next myArea
End With

End Sub

This looks for constants in column A--no formulas. But it could be modified.


"NetWave128 <" wrote:

I would prefer no loop because I don't know how to edit it...however if
that is the only way to do it, I probably should.

Additionally, the original data has a blank row(cell) between each set
of 4 properties. Is there anyway to to a copy.pastespecial.transpose
Skip blanks and have it correctly put the trasnposed data in multiple
rows instead of a sinlgle row as it is doing now.

thanks again

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


--

Dave Peterson



  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 171
Default Help Transposing Data from Row To Column

If the functions in the freely downloadable file at
http://home.pacbell.net/beban are available to your workbook, you can
array enter into a five column range with enough rows to accommodate all
the addresses. E.g., assuming 250 addresses in A1:A1000, array enter
into b1:f250

=ArrayReshape(A1:A1000,250,5)

Alan Beban

NetWave128 < wrote:
I would prefer no loop because I don't know how to edit it...however if
that is the only way to do it, I probably should.

Additionally, the original data has a blank row(cell) between each set
of 4 properties. Is there anyway to to a copy.pastespecial.transpose
Skip blanks and have it correctly put the trasnposed data in multiple
rows instead of a sinlgle row as it is doing now.

thanks again


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


  #7   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 171
Default Help Transposing Data from Row To Column

Actually, because of the blank lines, it would be 200 addresses, so
=ArrayReshape(A1:A1000,200,5)

Alan Beban

Alan Beban wrote:
If the functions in the freely downloadable file at
http://home.pacbell.net/beban are available to your workbook, you can
array enter into a five column range with enough rows to accommodate all
the addresses. E.g., assuming 250 addresses in A1:A1000, array enter
into b1:f250

=ArrayReshape(A1:A1000,250,5)

Alan Beban

NetWave128 < wrote:

I would prefer no loop because I don't know how to edit it...however if
that is the only way to do it, I probably should.

Additionally, the original data has a blank row(cell) between each set
of 4 properties. Is there anyway to to a copy.pastespecial.transpose
Skip blanks and have it correctly put the trasnposed data in multiple
rows instead of a sinlgle row as it is doing now.
thanks again


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



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
transposing a column johnsail Excel Discussion (Misc queries) 6 June 6th 09 04:58 PM
transposing data from 1 column into multiple rows Gina Excel Discussion (Misc queries) 2 April 5th 07 06:06 PM
Transposing a row into a column Raj Excel Discussion (Misc queries) 4 July 25th 06 10:09 PM
Transposing a column to several rows [email protected] Excel Worksheet Functions 4 May 26th 05 09:06 PM
Transposing one column into three Gilbert Excel Programming 11 November 10th 03 02:23 PM


All times are GMT +1. The time now is 12:36 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"