How to sort different areas of a spreadsheet differently?

boombox

New Member
Joined
Feb 24, 2012
Messages
12
I have a macro I'd like to develop...

We have a weekly invoice that comes in from a supplier and invariably there are many lines where the cell in the final column contains 0.00 to denote no value= no stock sent.

We tend to group any rows where no stock has come all together at the top and colour them red. Sorting doesn't really matter here, we don't column sort.

After that, though, we'd like to sort any column where the value isn't 0.00 by column 'A'.

Additionally (bonus points!) we then insert a column of tickboxes but I've never worked out how the script can calculate how many rows there are and fill down the tickboxes automatically like double clicking the fill down symbol does in regular use of Excel

many thanks in advance, sample data below, but obviously the regular spreadsheet has many more rows.


Invoice_391195_20210409.xlsx
ABCDEFGHIJKLM
1 CodeProduct CodeBrandChkboxProductTypeQtyPackSinglesRRPVATNet PriceNet Total
27394262515P0000Hozelock?Vortex Multi SprinklerSale00025.2920.00%00
3230246SHPR30KGarden?Hose & Spray Nozzle SetSale00024.9920.00%00
42678202292P9000Hozelock?Hose NozzleSale0009.220.00%00
58221192050P0025Hozelock?Hose End Connector Twin PackSale1101011.9920.00%49.8149.81
62266222976P0000Hozelock?Rectangular Sprinkler ProSale21268.4920.00%23.5947.18
72672302075 0000 Hozelock?Waterstop Connector StandardSale110107.2520.00%28.528.5
82266212335P0000Hozelock?Round Sprinkler Pro 2N1Sale21241.1920.00%13.827.6
91870107215P9000Hozelock?Starter Hose & Fitting SetSale21243.4920.00%13.7127.42
108279612294P0001Hozelock?Deluxe Hose NozzleSale31315.9920.00%5.1615.48
11230246SHPR30KGarden?Hose & Spray Nozzle SetSale11124.9920.00%11.0711.07
12230217SHPR30Garden?Reinforced Garden HoseSale11129.9920.00%10.1210.12
137394262515P0000Hozelock?Vortex Multi SprinklerSale11125.2920.00%9.629.62
142399802292P9008Hozelock?Nozzle Waterstop UnitSale1101015.9920.00%46.2546.25
152678202292P9000Hozelock?Hose NozzleSale110109.220.00%33.7133.71
166927142974P0000Hozelock?Rectangular Sprinkler PlusSale21239.9920.00%15.7731.54
Sheet1
 

Excel Facts

Which lookup functions find a value equal or greater than the lookup value?
MATCH uses -1 to find larger value (lookup table must be sorted ZA). XLOOKUP uses 1 to find values greater and does not need to be sorted.

Forum statistics

Threads
1,215,772
Messages
6,126,801
Members
449,337
Latest member
BBV123

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