+ Reply to Thread
Results 1 to 5 of 5

Delete rows that match multiple criteria

  1. #1
    Forum Contributor
    Join Date
    07-06-2007
    Posts
    101

    Delete rows that match multiple criteria

    Hi, I have a datasheet in excel 2003 with number of columns. I would like to be able to automatically delete any rows that match with criteria listed in a separate table. There are two columns in this spreadsheet, “Date” and “Start Time”. If weekday(Date) is equal to as listed in the criteria table and Start Time is between Start Time and End Time as listed in criteria table then delete that row. I have attached an example here. Could someone please help me with this? Thank you.
    Attached Files Attached Files

  2. #2
    Forum Contributor pr4t3ek's Avatar
    Join Date
    10-13-2008
    Location
    Melbourne, Australia
    MS-Off Ver
    2003 & 2007, 2010
    Posts
    483

    Re: Delete rows that match multiple criteria

    try this. *untested

    Please Login or Register  to view this content.
    Last edited by pr4t3ek; 11-09-2010 at 09:05 PM.
    --
    Regards
    PD

    ----- Don't Forget -----

    1. Use code tags. Place "[code]" before the first line of code and "[/code"]" after the last line of code. Exclude quotation marks

    2. Thank those who have helped you by Clicking the scales above each post.

    3. Please mark your post [SOLVED] if it has been answered satisfactorily.

  3. #3
    Forum Contributor
    Join Date
    07-06-2007
    Posts
    101

    Re: Delete rows that match multiple criteria

    Hi PD, for some reason the macro runs continuously and never seem to stops. Can you check the code again and see what is causing it to run non-stop.
    Thanks. gsrai

  4. #4
    Forum Contributor pr4t3ek's Avatar
    Join Date
    10-13-2008
    Location
    Melbourne, Australia
    MS-Off Ver
    2003 & 2007, 2010
    Posts
    483

    Re: Delete rows that match multiple criteria

    try this
    Please Login or Register  to view this content.
    this is untested also, sorry i'm not able to test this code but should work i believe.

  5. #5
    Forum Contributor
    Join Date
    07-06-2007
    Posts
    101

    Re: Delete rows that match multiple criteria

    Hi PD, thanks again, I tried new code but the macro still runs non-stop.
    Could you please check again for me. Thank you for your help.
    gsrai

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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