PC Review


Reply
Thread Tools Rate Thread

Creating multiple columns from one column

 
 
bblatz@bigeagle.ca
Guest
Posts: n/a
 
      9th Aug 2006
Hi,

I am stuck for an answer here so any help would be greatly appreciated.
What I'm trying to do is group 2 columns together and create two
columns of that group much like using the columns feature in word. I
would also like to have these columns alphabetized. It really isn't
important to me to be able to work with the file in columns, however I
would like to print with multiple columns to avoid having a 20 page
file to print.

Thanks

 
Reply With Quote
 
 
 
 
Gord Dibben
Guest
Posts: n/a
 
      9th Aug 2006
Sort the column first using Data>Sort

The run this macro to snake from top to bottom into as many columns as you
choose.

Public Sub SplitToCols()
Dim NUMCOLS As Integer
Dim I As Integer
Dim colsize As Long
On Error GoTo fileerror

NUMCOLS = InputBox("Choose Final Number of Columns")
colsize = Int((ActiveSheet.UsedRange.Rows.Count + _
(NUMCOLS - 1)) / NUMCOLS)
For I = 2 To NUMCOLS
Cells((I - 1) * colsize + 1, 1).Resize(colsize, 1).Copy Cells(1, I)
Next I
Range(Cells(colsize + 1, 1), Cells(Rows.Count, 1)).Clear
fileerror:
End Sub


Gord Dibben MS Excel MVP

On 9 Aug 2006 15:01:45 -0700, (E-Mail Removed) wrote:

>Hi,
>
>I am stuck for an answer here so any help would be greatly appreciated.
>What I'm trying to do is group 2 columns together and create two
>columns of that group much like using the columns feature in word. I
>would also like to have these columns alphabetized. It really isn't
>important to me to be able to work with the file in columns, however I
>would like to print with multiple columns to avoid having a 20 page
>file to print.
>
>Thanks


 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Creating two columns using a calculated column in the report kbrad32 Microsoft Access Reports 1 21st Oct 2008 07:31 PM
Creating a series from multiple columns and (multiple) files =?Utf-8?B?QmFkcmluYXRo?= Microsoft Excel Programming 0 18th Jul 2007 05:58 PM
Combine multiple columns into two long columns, Repeating rows in first column anasab@gmail.com Microsoft Excel Misc 2 31st Jul 2006 09:45 PM
Combine multiple columns into two long columns, Repeating rows in first column anasab@gmail.com Microsoft Excel Misc 0 31st Jul 2006 05:07 PM
Creating a form to fill multiple columns based first column... =?Utf-8?B?YmVnYW4=?= Microsoft Access Forms 1 25th Mar 2005 03:12 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 12:21 AM.