View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
Lynn Lynn is offline
external usenet poster
 
Posts: 131
Default String Contains a Value

Thanks Tom - this worked perfectly

"Tom Ogilvy" wrote:

if instr(1,cell.Value,"ABC",vbTextcompare) then
cell.EntireRow.Delete
end if

--
Regards,
Tom Ogilvy


"Lynn" wrote:

I would like a certain action to be carried out if a specified string is
found anywhere within the active cell. What code can I use to evaluate the
condition?

Eg if Customer is found anywhere in the active cell, I want to delete the
current row.