Sorting Columns to Single File

jackson4u

New Member
Joined
Jun 3, 2011
Messages
7
We have a school database..
We have nearly 100's of coulumns that are listed not in a format as shown in image.
Excel-Formating.jpg


Please see our current format and the output we need from the image..
Xls also attached..

http://seaplane.in/Excel-Multiple-Column-Sorting.xls

Output that is Needed

We need to list all names in a single column.

I Need to add only the values..
needs to remove the ones that does not contain the values

Is it possible to do have a function to does this automatically

How to sort multiple columns at the same time ?
If its possible how to do this ?

What we does now

We select individual column..
sort it and then copy one at a time to a OUTPUT column..
Repeat this for 100's of column

So its taking a long time

Can anyone help ?
 

Excel Facts

Repeat Last Command
Pressing F4 adds dollar signs when editing a formula. When not editing, F4 repeats last command.
Something along the lines of

Dim c As Range, rng
Dim LASTROW As Long

Set rng = Range("b1:m100")
For Each c In rng
If c.Value <> "" Then
LASTROW = Cells(Rows.Count, 1).End(xlUp).Row
Cells(LASTROW, 1).Offset(1, 0) = c.Value

End If
Next c
 
Upvote 0
Something along the lines of

Dim c As Range, rng
Dim LASTROW As Long

Set rng = Range("b1:m100")
For Each c In rng
If c.Value <> "" Then
LASTROW = Cells(Rows.Count, 1).End(xlUp).Row
Cells(LASTROW, 1).Offset(1, 0) = c.Value

End If
Next c


Thnkas you SteveO59L for your help..

But the problem is, as i am a newbie into EXCEL i am not sure how to Implement this code on my excel sheet..

Will you be able to upload that excel sheet for me so that I can see how it is done.

Or is there an another easy way to do get the output that I need ?
 
Upvote 0
Click on the developer tab.

On the left hand side you should have a " record macro" option.

Select this option, and the record the code in this workbook. then select the "stop recording" option.

Select the macros button and the code you have just recorded will be in the list of available macros.

Select the edit option, and paste the code between the sub / end sub lines.

Go back to your work sheet, select macros again this time select the run option
 
Upvote 0

Forum statistics

Threads
1,215,734
Messages
6,126,542
Members
449,316
Latest member
sravya

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top