Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 30
Default List Rows to Columns

On Sep 3, 4:13*pm, Patrick Molloy
wrote:
Option Explicit
Sub Combine()
* Dim rw As Long
* Dim cl As Long
* For rw = Range("A" & Rows.Count).End(xlUp).Row To 2 Step -1
* * If Cells(rw - 1, 1) < "" Then
* * * * For cl = 1 To Cells(rw, Columns.Count).End(xlToLeft).Column
* * * * * * Cells(rw - 1, Columns.Count).End(xlToLeft).Offset(, 1) =
Cells(rw, cl)
* * * * Next
* * * * Rows(rw).Delete
* * *End If
* * *If Cells(rw, 1) = "" Then Rows(rw).Delete
* Next
End Sub

"Ricky" wrote:
Hi,


I have an extensive contact list is column A, with each contact
separated by 2 empty rows.


Each contact has a varying amount of info such as address, phone
numbers etc, so some contacts occupy 5 lines, some 7 etc in columns A.


My problem - how do I re-arrange all these contacts in col A so that
one contact is displayed in one row. * This will then have all my 300
contacts being displayed in rows A1 down to A300.


Any help with a macro to achieve this would be greatly appreciated.


Regards, Ricky


Thanks Patrick and Tim. The macro Patrick is exactly what I was after
- tks

Ricky
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
create 1 master list from a combination of rows and columns Jason Excel Discussion (Misc queries) 3 August 17th 09 06:24 PM
How do I display a list of the rows or columns that I've hidden? indyogden Excel Discussion (Misc queries) 1 January 29th 09 05:12 AM
Controlling Hidden Rows / Columns in Filtered List KC VBA Qns Excel Programming 0 December 29th 06 07:44 AM
Creating a List Within Rows...Not Columns Tyrell Excel Programming 1 March 22nd 06 12:49 PM
Change a Column list into multiple rows & columns angelface Excel Worksheet Functions 3 January 28th 06 01:23 AM


All times are GMT +1. The time now is 06:41 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"