Deleting all rows that don't contain a word

rocknrisk

New Member
Joined
Apr 7, 2002
Messages
4
Hello,

Please can you help? I need to do this:

R1 R2 R3 R4 R5 R6 ...
C1 a bc def 123 rgt rdf <--- delete this row
C2 Word fgh poi kij 76 u <--- leave this row
C3 kjl gt hu f5 h9 787 <--- delete this row
C4 u78 hu g78 fv k0 h8 <--- delete this row
C5 Word b7 de4 xsd fght pl <--- leave this row
C6 Word gtyg tgt ii8 uy8 098 <--- leave this row
C7 gfh hghg yu 098ju iu jhy7 <--- delete this row
...

If anyone can help, it will be greatly appreciated.

Thank you.

Best Regards
Clinton
 

Excel Facts

Get help while writing formula
Click the italics "fx" icon to the left of the formula bar to open the Functions Arguments dialog. Help is displayed for each argument.
Hi Clinton
The easiest way is to use the data autofilter. Use the custom filter on Column C, towards the bottom in the drop down box select - Does not contain - type Word in the box to the right. This will then filter out all rows that do not have Word in them. Then just delete those rows.
Hope this helps
regards
Derek
This message was edited by Derek on 2002-04-08 06:24
 
Upvote 0
Lets say that A4:G11 houses the sample you provided:

{"R1","R2","R3","R4","R5","R6","R7";
"C1","a","bc","def",123,"rgt","rdf";
"C2","Word","fgh","poi","kij",76,"u";
"C3","kjl","gt","hu","f5","h9",787;
"C4","u78","hu","g78","fv","k0","h8";
"C5","Word","b7","de4","xsd","fght","pl";
"C6","Word","gtyg","tgt","ii8","uy8",98;
"C7","gfh","hghg","yu","098ju","iu","jhy7"}

Make sure that row 4, which contains labels, formatted distinctly, e.g., in bold and double underlined, and row 1 to 3 are empty before the row that contains labels that go with your data.

In A1 enter: R2
In A2 enter: Word

Activate A5.
Activate Data|Filter|Advanced Filter.
Check Copy to another location.
make sure that List range is: $A$4:$G$11.
Enter $A$1:$A$2 in the box for Criteria range.
Enter $I$1 in the box for Copy to.
Click OK.
 
Upvote 0

Forum statistics

Threads
1,213,536
Messages
6,114,208
Members
448,554
Latest member
Gleisner2

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