Auto-sort data which changes based on new data being input into another sheet

analyst91

New Member
Joined
Jun 16, 2016
Messages
4
Hi all,

I have data in the following form:
RegionValueVolume
North7341983409
South4298378374
East3842091024
West6364123412

<tbody>
</tbody>

The data in this sheet is derived using a sumif() and countif() function on a separate sheet, and I'm trying to create a macro to auto-sort this data everytime a value changes. Any ideas how I can go about this, as any code I try seems to be dead?! (I insert the macro through the 'View Code' option as usual).

Many Thanks!
 

Excel Facts

What is the shortcut key for Format Selection?
Ctrl+1 (the number one) will open the Format dialog for whatever is selected.
Do you just have the 4 lines of data? If so, I'd recommend just using some LARGE formulas to auto sort them. Which column(s) are you sorting by? Do you need to account for ties?

The reason that your code seems to be "dead" may be because that after it sorts the data, the way your formulas work they may recalculate afterward, giving the same numbers. If you copy and paste values to another location, your sort may work.
 
Upvote 0

Forum statistics

Threads
1,215,497
Messages
6,125,155
Members
449,208
Latest member
emmac

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