Delete row if inputted string not found

Closed
jaykay100 - Nov 21, 2008 at 12:53 AM
accordhda Posts 9 Registration date Tuesday October 21, 2008 Status Member Last seen May 16, 2009 - Nov 21, 2008 at 07:14 AM
Hello,
i am almost certain I have seen the answer to my question somewhere in here but no matter how I search it doesnt come up.

You have no idea how much we appreciate your help. You have saved my butt on a couple of occassions in the past but not recently.

What I need to do is have a macro which

#1. Asks me to input a column letter
#2. Asks me to input a string such as "Toyota"
#3 Searches for that string in each row in the column and, if the string is not found in the row, delete the entire row and move on to the next row until it runs out of rows.

**** There will be other data in the row in addition to the word "Toyota" *****
but, as long as the word "Toyota" or whatever string I enter at the beginning is found that row does not get deleted.

The files it will be searching will consist of no more than 15 columns but will have up to 26,000 rows, maybe even a few more on occassion.

Thanks in advance for any help given.

JK - San Dimas, CA

1 response

accordhda Posts 9 Registration date Tuesday October 21, 2008 Status Member Last seen May 16, 2009 1
Nov 21, 2008 at 07:14 AM
hey there,

just try out this link and see if you can find something there:

http://office.microsoft.com/en-us/excel/default.aspx?ofcresset=1
0