Consulting

Results 1 to 5 of 5

Thread: Solved: underline non duplicated values from 2 columns

  1. #1
    VBAX Mentor
    Joined
    Dec 2009
    Posts
    416
    Location

    Solved: underline non duplicated values from 2 columns

    compare two columns
    I have the first column (60 rows)
    1
    3
    d5
    f8
    r7
    t4
    y5
    etc
    and the second column (120 rows)

    1
    31
    ds
    f8
    r4
    t4
    y5
    q5
    r9
    etc
    it is possible to check if the values from the second column can be find in the first column. And if those are not in the first column to become underlined

  2. #2
    Administrator
    VP-Knowledge Base
    VBAX Grand Master mdmackillop's Avatar
    Joined
    May 2004
    Location
    Scotland
    Posts
    14,489
    Location
    You can do this with Conditional Formatting and a formula like
    =COUNTIF(B:B,A1)=0
    MVP (Excel 2008-2010)

    Post a workbook with sample data and layout if you want a quicker solution.


    To help indent your macros try Smart Indent

    Please remember to mark threads 'Solved'

  3. #3
    VBAX Mentor
    Joined
    Dec 2009
    Posts
    416
    Location
    it is working like this:
    A_____B_____C

    12____12____FALSE
    hj_____HJ___FALSE
    gh_____gh___FALSE
    hg_____gh___TRUE
    gh_____hg___TRUE

    but "hg" exist in column A and exist also in column B (not in the same rowlocation), in my case, I need to check if values from colB are in colA, if theare are NOT, underline

    a bit of VBA?

  4. #4
    Administrator
    VP-Knowledge Base VBAX Grand Master mdmackillop's Avatar
    Joined
    May 2004
    Location
    Scotland
    Posts
    14,489
    Location
    That is what the suggested solution will do.
    MVP (Excel 2008-2010)

    Post a workbook with sample data and layout if you want a quicker solution.


    To help indent your macros try Smart Indent

    Please remember to mark threads 'Solved'

  5. #5
    VBAX Mentor
    Joined
    Dec 2009
    Posts
    416
    Location
    correct , my bad, it is working the way I expected
    thank you.

Posting Permissions

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