ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Sorting alphabetical list into multiple columns (https://www.excelbanter.com/excel-worksheet-functions/105172-sorting-alphabetical-list-into-multiple-columns.html)

jp1733

Sorting alphabetical list into multiple columns
 

Hi,
I Have A Large List Of Customers And I Exported A Report Into Excel
That Has Their First And Last Name In One Column And Their Street
Address Only In The Second Column.

With 6000 Customers On My List, I Have Something Like 125-130 Pages Of
Customers In Size 7 Or 8 Font. With Only Two Rows Of Information On
Each Page, I'm Wasting A Lot Of Space To The Right Of All The Info On
Each Page.

I'm Trying To Make It So The Names Stay In Order And In Return Having
Multiple Columns Of Names On Each Page Instead Of Listing Them Straight
Down And Having 130 Pages

My Question Is:
How Can I Sort The Data So I Can Use The Whole Page And Carry The Very
Last Name On The Bottom Left Of The First Page To The Top-right Of The
First Page. For Example, John Doe -123 Bee St Is The Very Last Name And
Address On The First Page. How Can I Get The Next Name For Example,
(john Dunn) Which Is Supposed To Be On The Next Page To Move To The
Top-right Of The First Page.

I'm Sure There Is A Better Way Of Saying All Of That But I Hope You
Understand And Can Help

John


--
jp1733
------------------------------------------------------------------------
jp1733's Profile: http://www.excelforum.com/member.php...o&userid=37566
View this thread: http://www.excelforum.com/showthread...hreadid=571964


RagDyeR

Sorting alphabetical list into multiple columns
 
Check out this web page of David McRitchie:

http://www.mvps.org/dmcritchie/excel/snakecol.htm


--
HTH,

RD

---------------------------------------------------------------------------
Please keep all correspondence within the NewsGroup, so all may benefit !
---------------------------------------------------------------------------
"jp1733" wrote in
message ...

Hi,
I Have A Large List Of Customers And I Exported A Report Into Excel
That Has Their First And Last Name In One Column And Their Street
Address Only In The Second Column.

With 6000 Customers On My List, I Have Something Like 125-130 Pages Of
Customers In Size 7 Or 8 Font. With Only Two Rows Of Information On
Each Page, I'm Wasting A Lot Of Space To The Right Of All The Info On
Each Page.

I'm Trying To Make It So The Names Stay In Order And In Return Having
Multiple Columns Of Names On Each Page Instead Of Listing Them Straight
Down And Having 130 Pages

My Question Is:
How Can I Sort The Data So I Can Use The Whole Page And Carry The Very
Last Name On The Bottom Left Of The First Page To The Top-right Of The
First Page. For Example, John Doe -123 Bee St Is The Very Last Name And
Address On The First Page. How Can I Get The Next Name For Example,
(john Dunn) Which Is Supposed To Be On The Next Page To Move To The
Top-right Of The First Page.

I'm Sure There Is A Better Way Of Saying All Of That But I Hope You
Understand And Can Help

John


--
jp1733
------------------------------------------------------------------------
jp1733's Profile:
http://www.excelforum.com/member.php...o&userid=37566
View this thread: http://www.excelforum.com/showthread...hreadid=571964



Jim Cone

Sorting alphabetical list into multiple columns
 
You can also paste the data into Word and use its Columns feature.
Then paste the arranged data back into Excel
--
Jim Cone
San Francisco, USA
http://www.realezsites.com/bus/primitivesoftware


"jp1733"
wrote in message
Hi,
I Have A Large List Of Customers And I Exported A Report Into Excel
That Has Their First And Last Name In One Column And Their Street
Address Only In The Second Column.

With 6000 Customers On My List, I Have Something Like 125-130 Pages Of
Customers In Size 7 Or 8 Font. With Only Two Rows Of Information On
Each Page, I'm Wasting A Lot Of Space To The Right Of All The Info On
Each Page.

I'm Trying To Make It So The Names Stay In Order And In Return Having
Multiple Columns Of Names On Each Page Instead Of Listing Them Straight
Down And Having 130 Pages

My Question Is:
How Can I Sort The Data So I Can Use The Whole Page And Carry The Very
Last Name On The Bottom Left Of The First Page To The Top-right Of The
First Page. For Example, John Doe -123 Bee St Is The Very Last Name And
Address On The First Page. How Can I Get The Next Name For Example,
(john Dunn) Which Is Supposed To Be On The Next Page To Move To The
Top-right Of The First Page.

I'm Sure There Is A Better Way Of Saying All Of That But I Hope You
Understand And Can Help

John


--
jp1733
------------------------------------------------------------------------
jp1733's Profile: http://www.excelforum.com/member.php...o&userid=37566
View this thread: http://www.excelforum.com/showthread...hreadid=571964


Gord Dibben

Sorting alphabetical list into multiple columns
 
Assuming the two columns are sorted together aleady by selecting both and
DataSortAscending on Customer Name.

Then run this macro.

Original number of columns is 2
Rows per set is whatever you enter. 56 would be a good number to fit on a page.

When completed, you will wind up with 6 columns for printing.

Rows 1-56 in A and B
Rows 56-112 in C and D
Rows 113-168 in E and F

Then a blank row and repeat to end of data.

Sub Set_Three_Times()
Dim iSource As Long
Dim iTarget As Long
Dim cCols As Long
Dim rrows As Long

iSource = 1
iTarget = 1
cCols = InputBox("Original Number of Columns")
rrows = InputBox("rows per set")
Do
Cells(iSource, "A").Resize(rrows, cCols). _
Cut Destination:=Cells(iTarget, "A")
Cells(iSource + rrows, "A").Resize(rrows, cCols). _
Cut Destination:=Cells(iTarget, (cCols + 1))
Cells(iSource + (2 * rrows), "A").Resize(rrows, cCols). _
Cut Destination:=Cells(iTarget, (2 * cCols) + 1)
iSource = iSource + (rrows * (cCols + 1))
iTarget = iTarget + (rrows + 1)
Loop Until IsEmpty(Cells(iSource, "A").Value)

End Sub

If not familiar with VBA and macros, see David McRitchie's site for more on
"getting started".

http://www.mvps.org/dmcritchie/excel/getstarted.htm

In the meantime..........

First...create a backup copy of your original workbook.

To create a General Module, hit ALT + F11 to open the Visual Basic Editor.

Hit CRTL + R to open Project Explorer.

Find your workbook/project and select it.

Right-click and InsertModule. Paste the code in there. Save the
workbook and hit ALT + Q to return to your workbook.

Run the macro by going to ToolMacroMacros.

You can also assign this macro to a button or a shortcut key combo.



Gord Dibben MS Excel MVP


On Tue, 15 Aug 2006 17:06:10 -0400, jp1733
wrote:


Hi,
I Have A Large List Of Customers And I Exported A Report Into Excel
That Has Their First And Last Name In One Column And Their Street
Address Only In The Second Column.

With 6000 Customers On My List, I Have Something Like 125-130 Pages Of
Customers In Size 7 Or 8 Font. With Only Two Rows Of Information On
Each Page, I'm Wasting A Lot Of Space To The Right Of All The Info On
Each Page.

I'm Trying To Make It So The Names Stay In Order And In Return Having
Multiple Columns Of Names On Each Page Instead Of Listing Them Straight
Down And Having 130 Pages

My Question Is:
How Can I Sort The Data So I Can Use The Whole Page And Carry The Very
Last Name On The Bottom Left Of The First Page To The Top-right Of The
First Page. For Example, John Doe -123 Bee St Is The Very Last Name And
Address On The First Page. How Can I Get The Next Name For Example,
(john Dunn) Which Is Supposed To Be On The Next Page To Move To The
Top-right Of The First Page.

I'm Sure There Is A Better Way Of Saying All Of That But I Hope You
Understand And Can Help

John




All times are GMT +1. The time now is 09:00 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com