Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default reformat contact data

Hello everyone,

I know many may have this same problem, I hope the answer helps a lot of
people.

I have a list of 1000 contacts that are in vertical order, not very
database friendly. I would like to change the contact info so they are in
colums cells not row cells. Some have email address, some dont .
Their is a space between each orginal contact if that helps.I have tried may
methods but none has worked

Example

From this

Joe Smoe
122 W 123 Lake
Phila,Pa 19120
954-633-5656

Billy Bon
122 W 123 Lake
Phila,Pa 19120
954-633-4141

To this

Joe Smoe | 122 W 123 Lake | Philadelphia,Pa 19120 |954-633-5656
Billy Bon | 122 W 123 Lake | Philadelphia,Pa 19120 |954-633-4141

The more suggestions the better . Thank you very much for your help
Carl
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 84
Default reformat contact data

This will do it.

Bob Tulk
MOUS (XP/97)

------------
Sub ToCols()
'While not at the end of the list.
While ActiveCell.Row < 100
'If the next row is empty, we're done with this record.
x = 1
While ActiveCell.Offset(1, 0).Value < ""
ActiveCell.Offset(0, x).Value = ActiveCell.Offset(1, 0).Value
ActiveCell.Offset(1, 0).Delete xlUp
x = x + 1
Wend
'Move onto the next record.
ActiveCell.Offset(1, 0).Select
ActiveCell.Delete xlUp
Wend
End Sub
----------

"CarlJ" wrote:

Hello everyone,

I know many may have this same problem, I hope the answer helps a lot of
people.

I have a list of 1000 contacts that are in vertical order, not very
database friendly. I would like to change the contact info so they are in
colums cells not row cells. Some have email address, some dont .
Their is a space between each orginal contact if that helps.I have tried may
methods but none has worked

Example

From this

Joe Smoe
122 W 123 Lake
Phila,Pa 19120
954-633-5656

Billy Bon
122 W 123 Lake
Phila,Pa 19120
954-633-4141

To this

Joe Smoe | 122 W 123 Lake | Philadelphia,Pa 19120 |954-633-5656
Billy Bon | 122 W 123 Lake | Philadelphia,Pa 19120 |954-633-4141

The more suggestions the better . Thank you very much for your help
Carl

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default reformat contact data

hello Bob,
thank you very much for your reply. Your macro worked like a charm for the
small list.

Some of the larger list crashed. i did a print screen to show you . I also
included a link to a sample of the data I'm referring to.
I really appreciate your time and effert

Screen Shot www.johnsontraining.net/macro.jpg
Sample Sheet www.johnsontraining.net/sample_excel.xls

Thank you,
Carl



"BobT" wrote:

This will do it.

Bob Tulk
MOUS (XP/97)

------------
Sub ToCols()
'While not at the end of the list.
While ActiveCell.Row < 100
'If the next row is empty, we're done with this record.
x = 1
While ActiveCell.Offset(1, 0).Value < ""
ActiveCell.Offset(0, x).Value = ActiveCell.Offset(1, 0).Value
ActiveCell.Offset(1, 0).Delete xlUp
x = x + 1
Wend
'Move onto the next record.
ActiveCell.Offset(1, 0).Select
ActiveCell.Delete xlUp
Wend
End Sub
----------

"CarlJ" wrote:

Hello everyone,

I know many may have this same problem, I hope the answer helps a lot of
people.

I have a list of 1000 contacts that are in vertical order, not very
database friendly. I would like to change the contact info so they are in
colums cells not row cells. Some have email address, some dont .
Their is a space between each orginal contact if that helps.I have tried may
methods but none has worked

Example

From this

Joe Smoe
122 W 123 Lake
Phila,Pa 19120
954-633-5656

Billy Bon
122 W 123 Lake
Phila,Pa 19120
954-633-4141

To this

Joe Smoe | 122 W 123 Lake | Philadelphia,Pa 19120 |954-633-5656
Billy Bon | 122 W 123 Lake | Philadelphia,Pa 19120 |954-633-4141

The more suggestions the better . Thank you very much for your help
Carl

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
excel data table reformat datamanipulator Excel Discussion (Misc queries) 0 January 8th 09 07:20 PM
How do I reformat data into ranges Jerry Excel Discussion (Misc queries) 1 July 15th 08 03:28 AM
Need to reformat text data before or after importing to Excel Patti Ayala Excel Discussion (Misc queries) 2 October 13th 06 05:53 PM
Excel 2002 - ReFormat DATA mateo107 Excel Discussion (Misc queries) 3 April 12th 06 04:54 PM
Reformat data to vertical format Psydwaze Excel Discussion (Misc queries) 1 June 16th 05 05:32 PM


All times are GMT +1. The time now is 01:02 AM.

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

About Us

"It's about Microsoft Excel"