+ Reply to Thread
Results 1 to 4 of 4

Delete rows with Certain Criteria

  1. #1
    Valued Forum Contributor
    Join Date
    01-18-2007
    Location
    Georgia
    MS-Off Ver
    2010
    Posts
    4,434

    Delete rows with Certain Criteria

    Hello:

    Please refer to attached sheet.
    I have lots of employees with payroll info.

    Some of the employees are inactive.
    I like to VB Code to delete the row which has inactive employee info.
    If Sum(D:I) = 0 for any given employee, then that is inactive.

    In the attached sheet, Employee # 5, 6,10,13 and others are inactive and hence
    those needs to be deleted.

    Please let me know if any questions.

    Thank you

    Riz Momin
    Attached Files Attached Files
    Last edited by rizmomin; 10-15-2013 at 05:47 PM.

  2. #2
    Registered User
    Join Date
    09-24-2013
    Location
    Poland
    MS-Off Ver
    Excel 2010
    Posts
    22

    Re: Delete rows with Certain Criteria

    try this code
    Please Login or Register  to view this content.

  3. #3
    Valued Forum Contributor
    Join Date
    01-18-2007
    Location
    Georgia
    MS-Off Ver
    2010
    Posts
    4,434

    Re: Delete rows with Certain Criteria

    Hello:

    I tried below code which i found in another thread and it works great.
    Thanks.

    Please Login or Register  to view this content.

  4. #4
    Forum Expert
    Join Date
    03-28-2012
    Location
    TBA
    MS-Off Ver
    Office 365
    Posts
    12,454

    Re: Delete rows with Certain Criteria

    Hi Riz,
    A filter code would be faster, but this is another option
    Attached Files Attached Files

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] how to delete delete rows with criteria and keeping formula
    By Bremmah in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 04-18-2013, 07:09 AM
  2. [SOLVED] Delete certain rows with criteria
    By rizmomin in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 11-29-2012, 06:12 PM
  3. [SOLVED] Delete certain rows with criteria
    By rizmomin in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 11-28-2012, 01:22 PM
  4. vba to delete rows if criteria not met
    By peterkiukas in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 11-24-2007, 03:40 AM
  5. Delete rows with different criteria
    By John in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 07-13-2005, 01:05 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1