![]() |
Delete Rows
Hi All,
I was wondering if anyone could help me with a simple Macro code for Excel 97 for deleting rows. After I do I VLOOKUP, I would like a MACRO to automatically delete all rows that come back as "#N/A". Does anyone have any suggestions? Thanks ------------------------------------------------ ~~ Message posted from http://www.ExcelTip.com/ ~~ View and post usenet messages directly from http://www.ExcelForum.com/ |
Delete Rows
Assume your formulas are in column C Dim rng as Range On Error Resume Next set rng = Columns(3).SpecialCells(xlFormulas,xlErrors) On Error goto 0 if not rng is nothing then rng.Entirerow.Delete End if -- Regards, Tom Ogilvy "STEVEB" wrote in message ... Hi All, I was wondering if anyone could help me with a simple Macro code for Excel 97 for deleting rows. After I do I VLOOKUP, I would like a MACRO to automatically delete all rows that come back as "#N/A". Does anyone have any suggestions? Thanks ------------------------------------------------ ~~ Message posted from http://www.ExcelTip.com/ ~~ View and post usenet messages directly from http://www.ExcelForum.com/ |
Delete Rows
Tom,
Thanks for everything! The formula worked great, I appreciate your help. Steve ------------------------------------------------ ~~ Message posted from http://www.ExcelTip.com/ ~~ View and post usenet messages directly from http://www.ExcelForum.com/ |
All times are GMT +1. The time now is 12:34 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com