Forum

Delete Entire Row b...
 
Notifications
Clear all

Delete Entire Row based on the Given Criteria in Excel VBA

2 Posts
2 Users
0 Reactions
162 Views
(@ragreloks)
Posts: 1
New Member
Topic starter
 

Hi, I need to delete the entire rows in 3 sheets based on the following criteria:

If
In Sheets. 'Sponsored Products Campaigns'
>If Column B does NOT have "Keyword" or "Product Targeting" OR
>If Column S does NOT have "enabled" OR
>If Column AS does NOT have "enabled" OR
>If Column AT does NOT have "enabled"

In Sheets. 'Sponsored Brands Campaigns'
>If Column B does NOT have "Keyword" or "Product Targeting" OR
>If Column Q does NOT have "enabled" OR
>If Column R does NOT have "running" or "other"
>If Column AY does NOT have "enabled"

In Sheets. 'Sponsored Display Campaigns'
>If Column B does NOT have "Audience Targeting" or "Product Targeting" OR
>If Column M does NOT have "enabled" OR
>If Column AL does NOT have "enabled" OR
>If Column AM does NOT have "enabled"

Then Delete the entire row.

NOTE: These all OPERATIONS are ORED means if any single criteria is met, I need to delete that entire row.

NOTE2: Please don't merge/combine code for all 3 sheets, as I will place these codes in a bigger code on different places, and depending on a condition, one will run and others won't.

NOTE3: Kindly use as minimum variables as possible as they mess up the bigger code.

NOTE4: I am attaching the sheet having all the 3 sheets.

NOTE5: I know there are multiple method to achieve the same result, please consider the most efficient way to do that considering rows from 5k - 100k

 
Posted : 03/04/2022 9:25 pm
Alan Sidman
(@alansidman)
Posts: 220
Member Moderator
Share: