+ Reply to Thread
Results 1 to 15 of 15

Delete Rows based on cell value, highlight based on cell value and keep deleted data

  1. #1
    Forum Contributor
    Join Date
    04-14-2017
    Location
    Auckland
    MS-Off Ver
    2016
    Posts
    119

    Delete Rows based on cell value, highlight based on cell value and keep deleted data

    Hi Experts

    I need your expertise to help me in this.

    Based on the cell value (Column D), I would need a code that matches the value in Column D of Master Sheet with Column A in the second tab (EXEMPT) to delete the rows from master sheet and keep the records a new worksheet.

    The code should also match the Column D of Master Sheet with Column A of third tab (NATCON) and highlight them.

    Is this doable please? I have attached the sample data.

    Thanks

    Jared
    Attached Files Attached Files

  2. #2
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,162

    Re: Delete Rows based on cell value, highlight based on cell value and keep deleted data

    Hi jared

    One way with filter...
    Please Login or Register  to view this content.
    Not sure if you are aware...You have "WAIPUNA" as deletion and highlight value?

    What does this mean...
    and keep the records a new worksheet.
    If it means to place the deleted data to a new sheet then make use of this instead of above...
    Please Login or Register  to view this content.
    Last edited by sintek; 11-06-2020 at 02:39 AM.
    Good Luck
    I don't presume to know what I am doing, however, just like you, I too started somewhere...
    One-day, One-problem at a time!!!
    If you feel I have helped, please click on the star to left of post [Add Reputation]
    Also....add a comment if you like!!!!
    And remember...Mark Thread as Solved.
    Excel Forum Rocks!!!

  3. #3
    Forum Contributor
    Join Date
    04-14-2017
    Location
    Auckland
    MS-Off Ver
    2016
    Posts
    119

    Re: Delete Rows based on cell value, highlight based on cell value and keep deleted data

    Awesome, worked like a magic.

    Thank you so much.

  4. #4
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,162

    Re: Delete Rows based on cell value, highlight based on cell value and keep deleted data

    ..........................
    THANKS.gif

  5. #5
    Forum Contributor
    Join Date
    04-14-2017
    Location
    Auckland
    MS-Off Ver
    2016
    Posts
    119

    Re: Delete Rows based on cell value, highlight based on cell value and keep deleted data

    Hi Sintek

    Sorry to be a pain, just had another requirement added to the last one and need your help if you could please.

    in the attached sample data, now

    We need to match between Column C in Sheet 1 with "CUSTOMER GROUP", Column D in Sheet 1 with "CUSTOMER NUMBER" and Column D in Sheet 1 with "CUSTOMER DESCRIPTION" and delete the matches and place them to the "DELETED" Sheet.

    "NATCON" should be matched with Column C in Sheet 1 and highlighted the duplicates.

    Is it doable? "Customer Description" should not be 100% match, like if most of the description matches it should pick and place them to DELETED sheet.

    Thank you heaps for your help
    Attached Files Attached Files

  6. #6
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,162

    Re: Delete Rows based on cell value, highlight based on cell value and keep deleted data

    Hi Jared

    Have a project deadline...No time at the moment...If no one else has provided a solution, will check it out when I get a moment...

  7. #7
    Forum Contributor
    Join Date
    04-14-2017
    Location
    Auckland
    MS-Off Ver
    2016
    Posts
    119

    Re: Delete Rows based on cell value, highlight based on cell value and keep deleted data

    Thanks you Sir, much appreciated.

  8. #8
    Forum Contributor
    Join Date
    04-14-2017
    Location
    Auckland
    MS-Off Ver
    2016
    Posts
    119

    Re: Delete Rows based on cell value, highlight based on cell value and keep deleted data

    No one has provided a solution yet, if you could please have a chance to look at when you can please. thanks.

  9. #9
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,162

    Re: Delete Rows based on cell value, highlight based on cell value and keep deleted data

    Please explain in detail step by step what you are wanting to achieve...Also supply a sample file with expected outcome and explain how you achieved this...

  10. #10
    Forum Contributor
    Join Date
    04-14-2017
    Location
    Auckland
    MS-Off Ver
    2016
    Posts
    119

    Re: Delete Rows based on cell value, highlight based on cell value and keep deleted data

    Thanks, i have updated the sample data. All the highlighted rows should be deleted from Sheet 1 and be placed into the DELETED worksheet,

    We need to match

    Sheet 1 Column C = Customer Group
    Sheet 1 Column D = Customer Number and
    Sheet 1 Column E = Customer Description (Should pick the most match)

    Sheet 1 Column C = NATCON to highlight the cells in Column C.

    You have previously given me the code as below which was perfect but need a revised one for this now please, thank you


    Please Login or Register  to view this content.
    Attached Files Attached Files
    Last edited by jaredli; 11-19-2020 at 08:44 PM.

  11. #11
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,162

    Re: Delete Rows based on cell value, highlight based on cell value and keep deleted data

    Had a couple minutes free...Can only check back next week again...

    Please Login or Register  to view this content.
    By the way...take Note...
    Your post above does not comply with Rule # 2
    2. Programming code must be enclosed in code tags to improve readability. (A, Z)
    Please Login or Register  to view this content.
    So...Edit your post...Highlight the code and press the # button

  12. #12
    Forum Contributor
    Join Date
    04-14-2017
    Location
    Auckland
    MS-Off Ver
    2016
    Posts
    119

    Re: Delete Rows based on cell value, highlight based on cell value and keep deleted data

    Sorry My bad, i have corrected this now.

    This code didn't work and giving me the error that i have attached.
    Attached Images Attached Images

  13. #13
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,162

    Re: Delete Rows based on cell value, highlight based on cell value and keep deleted data

    Sample upload had different sheet numbers...
    This works...
    Attached Files Attached Files

  14. #14
    Forum Contributor
    Join Date
    04-14-2017
    Location
    Auckland
    MS-Off Ver
    2016
    Posts
    119

    Re: Delete Rows based on cell value, highlight based on cell value and keep deleted data

    Awesome, you're a gem. Thanks and God bless you!

  15. #15
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,162

    Re: Delete Rows based on cell value, highlight based on cell value and keep deleted data

    My pleasure...

    Thank you. God bless you too.

+ 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. Highlight (visible) rows Based on cell value
    By ptmuldoon in forum Excel General
    Replies: 1
    Last Post: 07-27-2018, 04:45 PM
  2. [SOLVED] VBA - Highlight Range(Rows) based on cell value
    By rxk in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 09-20-2017, 03:01 AM
  3. [SOLVED] Highlight particular rows based on cell selection
    By chickpeazy in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 05-31-2017, 10:13 AM
  4. Highlight Rows based on cell value
    By Tortus in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-02-2016, 03:49 PM
  5. Highlight Rows Based on Corresponding Cell Value
    By zealot in forum Excel General
    Replies: 2
    Last Post: 02-18-2012, 08:35 AM
  6. How to delete rows of data based on cell values in VB?
    By drx in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-24-2011, 04:45 PM
  7. Delete multiple rows of data based on criteria in a single cell
    By slaga9 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-12-2011, 03:41 AM

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