clear rows meeting criteria - vba help!

Status
Not open for further replies.

HimThruMe

Board Regular
Joined
Jun 26, 2008
Messages
117
i need to write code that clears the entire row if it has the word "backordered" in the N Column.

any suggestions? :)
 

Some videos you may like

Excel Facts

Excel Joke
Why can't spreadsheets drive cars? They crash too often!

schielrn

Well-known Member
Joined
Apr 4, 2007
Messages
6,939
Do you really need to use vba for this? you can use autofilter and filter on column N for "backordered" and then clear out all the cells?

Otherwise you could record a macro doing that task? But if you really must need a vba apporach please post back and I will write something up.

Hope that helps.
 

HimThruMe

Board Regular
Joined
Jun 26, 2008
Messages
117
i need it in vba because it occurs (among other things) at the click of a button... all the backordered data is being copied and moved to another page using this code here:

Range("BOInvoice").AdvancedFilter Action:=xlFilterCopy, CriteriaRange:=Range( _
"n3:n4"), CopyToRange:=Range("a21:l48"), Unique:=False

the problem is that it only copies it... i need it to remove it from the original range ("BOInvoice") after it moves it... i cant seem to find the option of cut the data and pasting it using the advanced filter... any suggestions?
 
Status
Not open for further replies.

Watch MrExcel Video

Forum statistics

Threads
1,123,488
Messages
5,601,974
Members
414,487
Latest member
inxlsplot

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
Top