request for help

Peter3580

New Member
Joined
Feb 17, 2018
Messages
17
I have a series of numbers in a cells in a column e.g. 5632
4361
3343
2434
3352
I need a formula that will put the numbers into descending numerical order e.g.
6532
6431
4333
4332
5332
I am really new to excel and don't even know if this is possible - its easy to do without a formula but would be nice
 

Excel Facts

Pivot Table Drill Down
Double-click any number in a pivot table to create a new report showing all detail rows that make up that number
you could try the following in the next column

=LARGE(H:H,ROWS($H$1:H1))

Obviously use the column you want, and copy down as to actually changing the numbers in place, I don't think that is possible without vba
 
Upvote 0
If you can use this UDF it should do the job
Code:
Function Srt(R [COLOR="Navy"]As[/COLOR] Range) [COLOR="Navy"]As[/COLOR] [COLOR="Navy"]Long[/COLOR]
[COLOR="Navy"]Dim[/COLOR] i, x() [COLOR="Navy"]As[/COLOR] Byte
x = StrConv(R, vbFromUnicode)
[COLOR="Navy"]For[/COLOR] i = 0 To UBound(x)
    Srt = Srt & Chr$(Application.Large(x, i + 1))
[COLOR="Navy"]Next[/COLOR]
[COLOR="Navy"]End[/COLOR] Function


To Save and Run UDF:-
Copy Function from Thread
In Your Data sheet , Click "Alt+F11",:- Vb Window appears.
From the VBWindow toolbar, Click "Insert" ,"Module":- New VBwindow appears .
Paste Code into this window.
Close Vbwindow.

In sheet, Add the "function" in cell "B1"as:- =Srt(A1)
NB:- Once you've added the first bracket you can select the range "A1" from the sheet
Then click "Enter" to show result
Drag Function down remaining numbers



Regards Mick

 
Upvote 0
Hi Mick Actually it worked on a trial sheet but not in my 'real'

Calculating High Card Points
D1
NORTHCELL 1CELL 2CELL 3CELL 4
SPADES40000300000000007H88113#NAME ?UnBalanced
HEARTS00000000000000000C1
CLUBS00010000000000001P1
DIAMONDS03000020000000005133
<colgroup><col width="92" style="width: 69pt; mso-width-source: userset; mso-width-alt: 2717;"> <col width="26" style="width: 20pt; mso-width-source: userset; mso-width-alt: 768;"> <col width="23" style="width: 18pt; mso-width-source: userset; mso-width-alt: 689;" span="16"> <col width="30" style="width: 23pt; mso-width-source: userset; mso-width-alt: 886;"> <col width="11" style="width: 9pt; mso-width-source: userset; mso-width-alt: 334;"> <col width="23" style="width: 18pt; mso-width-source: userset; mso-width-alt: 689;"> <col width="23" style="width: 18pt; mso-width-source: userset; mso-width-alt: 689;"> <col width="49" style="width: 37pt; mso-width-source: userset; mso-width-alt: 1457;"> <col width="14" style="width: 11pt; mso-width-source: userset; mso-width-alt: 413;"> <col width="13" style="width: 10pt; mso-width-source: userset; mso-width-alt: 393;"> <col width="83" style="width: 63pt; mso-width-source: userset; mso-width-alt: 2461;"> <col width="102" style="width: 77pt; mso-width-source: userset; mso-width-alt: 3012;"> <tbody> </tbody>

When I use the =Srt(X4) the column where my numbers are, I get the #NAME ? error. I cant see any thing wrong with the code so what else am I doing wrong?

Peter
 
Upvote 0
Based upon your data column "X" has 4 vertical cells with the an individual numbers in each of the 4 cells i.e :- 8,1,1,3.
The actual number in 8113 appears to be in cell "Z4" not "X4" . !!
 
Upvote 0

Forum statistics

Threads
1,215,398
Messages
6,124,688
Members
449,179
Latest member
kfhw720

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