+ Reply to Thread
Results 1 to 5 of 5

Need Formula for blank out duplicate cells based on value that is changes in another colum

  1. #1
    Registered User
    Join Date
    08-18-2021
    Location
    UAE
    MS-Off Ver
    365
    Posts
    8

    Need Formula for blank out duplicate cells based on value that is changes in another colum

    Hello

    I'm looking for a formula that would blank out cells in Column B and not delete the entire row when duplicate data is found but the trick is that it needs to be based on when there is duplicate data in column A then it should just keep one value in column B and all other values related to that other column should be blank.

    Column A Column B
    ABC 123
    ABC 123
    ABC 123
    DEF 456
    DEF 456
    DEF 456

    So my result should be like this

    Column A Column B
    ABC 123
    ABC
    ABC

    Thank you.
    Last edited by Waseem0888; 10-06-2021 at 05:21 AM.

  2. #2
    Forum Guru Kaper's Avatar
    Join Date
    12-14-2013
    Location
    Warsaw, Poland
    MS-Off Ver
    most often: Office 365 in Windows environment
    Posts
    8,623

    Re: Need Formula for blank out duplicate cells based on value that is changes in another c

    Assuming your data starts with row 2 in C2 (and copied down) such formula would do the job:
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    PS. If you would like changes in column B, where the data alrteady resides, formula wouldn't help, you need to use for instance VBA code to achieve this result
    PS2. Please note yellow banner above - the attachment (workbook) is often very helpful and better than text inside the post
    Attached Files Attached Files
    Best Regards,

    Kaper

  3. #3
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,734

    Re: Need Formula for blank out duplicate cells based on value that is changes in another c

    You could maybe use conditional formatting to "blank them out", by setting the foreground colour the same as the background colour. This would not change the values in the cells, but would effectively make them appear as blanks.

    Hope this helps.

    Pete

  4. #4
    Registered User
    Join Date
    08-18-2021
    Location
    UAE
    MS-Off Ver
    365
    Posts
    8

    Re: Need Formula for blank out duplicate cells based on value that is changes in another c

    @Kaper

    Thank you for your kind help. Ok sorry about that yes i am uploadind my workbook i have tried your formula but i want it reflect in the orignal coulumn dont want to creat new column how i can do that? i have tried through conditional formating but i am not getting blank can you please help based on the values in column A the refrence number will have duplicate values and i want to apply formula to column M and column N to balnkout the dates and keep only one date.If we have to done it trough VBA than how it can be done. Your help is highly appritiated. Thankyou
    Attached Files Attached Files
    Last edited by AliGW; 10-07-2021 at 05:15 AM. Reason: PLEASE don't quote unnecessarily!

  5. #5
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,734

    Re: Need Formula for blank out duplicate cells based on value that is changes in another c

    Select the cells M3:N31 so you can set the CF in one operation, then click on Conditional Formatting | New Rule | Use a formula... , and then put this formula in the dialogue box which pops up:

    =COUNTIFS($A$3:$A3,$A3,M$3:M3,M3)>1

    Click on the Format button, Font tab, then in the Color drop-down choose white, then OK twice to exit the dialogue box. Excel will adjust the (relative) cell references to suit the cells that had been selected, so that the duplicates will appear blanked out.

    Hope this helps.

    Pete

+ 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. Replies: 4
    Last Post: 07-25-2017, 12:26 PM
  2. [SOLVED] Find last used column in row 1, then autoreplace all blank cells in row 2 UP to that colum
    By ks100 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-05-2014, 02:53 PM
  3. Replies: 2
    Last Post: 10-18-2013, 11:18 AM
  4. Replies: 7
    Last Post: 02-10-2013, 02:10 AM
  5. Create duplicate rows for a single colum with 'x2' or 'x3' are in cells.
    By justchil in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 09-16-2012, 06:15 PM
  6. Replies: 2
    Last Post: 06-26-2010, 06:59 AM
  7. [SOLVED] find range of non-blank cells in colum
    By DJS in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 06-26-2006, 05:30 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