Need to filter out certain rows in an excel spreadsheet

Posted on 2015-02-04
Last Modified: 2015-02-12
I have a large spreadsheet to modify, but have included a small sample (attached) for explanation.

I only want certain rows.  

For example, I want Row 2 because there is a # sign in column A beside it.  I do NOT want Row 1 because there is a Row 2 where R1C2 matches R2C2.

Another Example:  I only want row 8, not row 7 or row 9, because a row exists with G0105 in column B and a # sign in column A.

I DO want the rows 14 through 18, however,because there are no rows where a # sign exists for those identifiers in column B.

So the # sign trumps all, but in addition I want to exclude any rows where there is a value in column C.

Does anyone know how to do this?
Question by:Becky Edwards
  • 4
  • 3
LVL 26

Expert Comment

ID: 40589904
run the macro in the attached workbook and it will do the job

Author Comment

by:Becky Edwards
ID: 40590041
I tried it, we are almost there!.  Except it removed all the rows where there were no # signs in the row.  I need those rows also, if no row exists for that Code (example G0108) with a # sign beside it.  

I DO want the rows 14 through 18, however,because there are no rows where a # sign exists for those identifiers in column B.
LVL 26

Expert Comment

ID: 40590139
i do not understand the requirement.

can u upload the file, by deleting all of the rows that need to be deleted and leave those need to stay.
Connect further...control easier

With the ATEN CE624, you can now enjoy a high-quality visual experience powered by HDBaseT technology and the convenience of a single Cat6 cable to transmit uncompressed video with zero latency and multi-streaming for dual-view applications where remote access is required.


Author Comment

by:Becky Edwards
ID: 40591579
I need EXCEL to evaluate each row and delete if necessary.  

In the attached file,
I do not need row one because row two exists, for G0101, with a # sign in column a. Delete row one.
I do not need row three because row four exists, for G0102, with a # sign in column a.  Delete row three.
The same for rows 5,6,7,8,9,10.  I want to keep the rows 6,8, 10 and delete rows 5,7,9.
I need row 11 for code G0106 because rows 12 and 13 for G0106 have modifiers in column C, so that disqualifies rows 12 and 13.  Delete rows 12 and 13.
I need row 14 - 18 because no row exists with a # sign for those codes in column B, G0108 through G0120.

Does this help?  Thank you for your patience!
LVL 26

Accepted Solution

ProfessorJimJam earned 500 total points
ID: 40602590
please see attached file.  run the macro "deleterows"

Author Closing Comment

by:Becky Edwards
ID: 40605797
Wow.  This is awesome.  You just corrected my huge spreadsheet in seconds.  Something the girl at work here takes hours to do by hand.  

I really appreciate your hard work, and the fact you are willing to share with others.

Your my hero.

Thank you ProfessorJimJam
LVL 26

Expert Comment

ID: 40605800
You are welcome.

Thanks for feedback.

Featured Post

Portable, direct connect server access

The ATEN CV211 connects a laptop directly to any server allowing you instant access to perform data maintenance and local operations, for quick troubleshooting, updating, service and repair.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Today companies are subjected to more-and-more data, and it won't stop any time soon.  But there are obvious opportunities for reducing data, particularly data duplicated among companies.
: Microsoft Office Collaborate for free and online versions of Microsoft  Word, Excel, Powerpoint, OneNote, Onedrive , Email, Calendar etc. In short we can say that Microsoft office is a suite of servers, applications and services developed by  Micr…
The viewer will learn how to edit text. This includes Font, Spacing, Resizing, Color, and other special text options.
This video shows where to find templates, what they are used for, and how to create and save a custom template using Microsoft Word.

821 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question