delete rows when value is within an interval in col 3

  • Thread starter Thread starter Guest
  • Start date Start date
lr=cells(rows.count,"c").end(xlup).row
for i=2 to lr
if cells(i,"c")>999 and cells(i,"c")<1100 then rows(i).delete
next
 
Hi Don

It works only for one line at a time - it does not check all lines. It stops
and you need to repeat the macro.

Any ideas?

Br

"Don Guillett" skrev:
 
Hi Don

Can I send you a mail with the doc as attach. and you can see what happens?

I think something is wrong with the row count.

Sverre

"Don Guillett" skrev:
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top