Delete rows if a group does not contain a colored cell

farmerjack190

New Member
Joined
May 17, 2016
Messages
11
I have a sheet which we use to aid a our warehouse movements when new stock arrives (ZFLOOR) location. What I am needing to do is to have a script that can remove a block of items if "ZFLOOR" is not contained.
In this example I need to remove rows 7-10, 12-13, 15-16 and preferably the blank row below to keep formatting etc but need to keep data in rows 21-22 in this case. Obviously "ZFLOOR" will change each time but always in Column P so rows to be deleted will be subject to a group not containing ZFLOOR or a Green conditional formatted cell.

Have no idea where to start, any help appreciated.
 

Attachments

  • 2021-11-22.png
    2021-11-22.png
    44.2 KB · Views: 12

Excel Facts

What is the shortcut key for Format Selection?
Ctrl+1 (the number one) will open the Format dialog for whatever is selected.
You're welcome, glad to help & thanks for the feedback.:)
 
Upvote 0

Forum statistics

Threads
1,214,642
Messages
6,120,700
Members
448,979
Latest member
DET4492

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