+ Reply to Thread
Results 1 to 7 of 7

Remove duplicates without removing formatting?

  1. #1
    Forum Contributor
    Join Date
    08-16-2010
    Location
    Holland, MI
    MS-Off Ver
    Excel 2007
    Posts
    110

    Remove duplicates without removing formatting?

    All,
    I have the following line of code in my macro...

    Please Login or Register  to view this content.
    This finds duplicates in columns 1 and 9 and then removes everything in that row, including the formatting. Can this line of code be changed to remove values only but leave shading a boarders? Thanks for any suggestions.

  2. #2
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,259

    Re: Remove duplicates without removing formatting?

    Hello jfoerch,

    There are no options in this method to keep the formatting. You can use the macro below to do so.

    Custom Macro to Remove Duplicates and Leave the Formatting
    Please Login or Register  to view this content.
    Example of Calling the Macro
    Please Login or Register  to view this content.
    Sincerely,
    Leith Ross

    Remember To Do the Following....

    1. Use code tags. Place [CODE] before the first line of code and [/CODE] after the last line of code.
    2. Thank those who have helped you by clicking the Star below the post.
    3. Please mark your post [SOLVED] if it has been answered satisfactorily.


    Old Scottish Proverb...
    Luathaid gu deanamh maille! (Rushing causes delays!)

  3. #3
    Forum Contributor
    Join Date
    08-16-2010
    Location
    Holland, MI
    MS-Off Ver
    Excel 2007
    Posts
    110

    Re: Remove duplicates without removing formatting?

    Wow. There's stuff in there that I've never seen before. I'll give that a try. Is there a way to remove the entire row with the duplicate rather than deleting the cell values and formats?

  4. #4
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,259

    Re: Remove duplicates without removing formatting?

    Hello jfoerch,

    Sure, just change this line...
    Please Login or Register  to view this content.
    To this...
    Please Login or Register  to view this content.

  5. #5
    Forum Contributor
    Join Date
    08-16-2010
    Location
    Holland, MI
    MS-Off Ver
    Excel 2007
    Posts
    110

    Re: Remove duplicates without removing formatting?

    Thanks for the reply. I was meaning using my original line of code, can I re-write it to delete the whole row rather that just deleting the cell values and formats? My original line of code works perfect for what I want to do, except I lose the formatting. If I can make the whole duplicate row go away, then I can also achieve my goal.

    Thanks

  6. #6
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,259

    Re: Remove duplicates without removing formatting?

    Hello jfoerch,

    From post #2
    There are no options in this method to keep the formatting. You can use the macro below to do so.

  7. #7
    Forum Contributor
    Join Date
    08-16-2010
    Location
    Holland, MI
    MS-Off Ver
    Excel 2007
    Posts
    110

    Re: Remove duplicates without removing formatting?

    Yeah. I understand that now, I can't remove duplicates but still preserve the formatting. But, can I remove duplicates and delete the entire row?

+ 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] Removing Unused Lines After Remove Duplicates
    By freybe06 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 09-16-2013, 07:30 PM
  2. [SOLVED] Removing Unused Lines After Remove Duplicates
    By freybe06 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 09-16-2013, 04:51 PM
  3. [SOLVED] Remove duplicates without removing cells (leave blank)
    By RobertOHare in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 07-10-2013, 09:57 AM
  4. [SOLVED] Remove Duplicates issue...Not Removing as it should
    By trosasco in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 05-24-2013, 12:57 PM
  5. Remove Duplicates not removing all duplicate entries
    By Rick_Stanich in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-20-2008, 05:32 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