+ Reply to Thread
Results 1 to 4 of 4

Message box display after using conditional formatting to identify duplicate values

  1. #1
    Registered User
    Join Date
    10-03-2016
    Location
    England
    MS-Off Ver
    2013
    Posts
    2

    Message box display after using conditional formatting to identify duplicate values

    Hello,

    I have recorded a macro to highlight duplicates cell values in column F:F in sheet 1 and and Column F:F in sheet 2. I would like to have a message box displayed at the end of running macro to show which sheet has a duplicate value.

    Please help.

    Thanks in advance.

  2. #2
    Valued Forum Contributor
    Join Date
    10-05-2014
    Location
    Regina, SK Canada
    MS-Off Ver
    Excel for Mac 11
    Posts
    330

    Re: Message box display after using conditional formatting to identify duplicate values

    Please share your macro so we can see what you tried.
    Sharing the workbook with your (sample) data helps also.
    If this has been helpful, please click on the star at the left.

  3. #3
    Forum Expert gmr4evr1's Avatar
    Join Date
    11-24-2014
    Location
    Texas
    MS-Off Ver
    Office 2010 and 2007
    Posts
    3,448

    Re: Message box display after using conditional formatting to identify duplicate values

    It might be helpful if you could post the code you are using. Be sure to use code tags around the code
    Please Login or Register  to view this content.
    1N73LL1G3NC3 15 7H3 4B1L17Y 70 4D4P7 70 CH4NG3 - 573PH3N H4WK1NG
    You don't have to add Rep if I have helped you out (but it would be nice), but please mark the thread as SOLVED if your issue is resolved.

    Tom

  4. #4
    Registered User
    Join Date
    10-03-2016
    Location
    England
    MS-Off Ver
    2013
    Posts
    2

    Re: Message box display after using conditional formatting to identify duplicate values

    Hi,

    Here is the macro I recorded. I want a message box to be added to tell there are duplicates in Sheet "Permanent" or "Contract Calculation".

    Sub Checkforduplicates()
    '
    ' Checkforduplicates Macro
    '
    ' Keyboard Shortcut: Ctrl+e
    '
    Sheets("Permanent").Select
    Columns("F:F").Select
    Selection.FormatConditions.AddUniqueValues
    Selection.FormatConditions(Selection.FormatConditions.Count).SetFirstPriority
    Selection.FormatConditions(1).DupeUnique = xlDuplicate
    With Selection.FormatConditions(1).Interior
    .PatternColorIndex = xlAutomatic
    .Color = 255
    .TintAndShade = 0
    End With
    Selection.FormatConditions(1).StopIfTrue = False
    Sheets("Contract Calculation").Select
    Columns("F:F").Select
    Selection.FormatConditions.AddUniqueValues
    Selection.FormatConditions(Selection.FormatConditions.Count).SetFirstPriority
    Selection.FormatConditions(1).DupeUnique = xlDuplicate
    With Selection.FormatConditions(1).Interior
    .PatternColorIndex = xlAutomatic
    .Color = 255
    .TintAndShade = 0
    End With
    Selection.FormatConditions(1).StopIfTrue = False
    Sheets("Permanent").Select
    Range("A2").Select
    End Sub

    Thanks

+ 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: 2
    Last Post: 10-03-2016, 09:57 AM
  2. Conditional Formatting and Duplicate Values
    By bgarner10 in forum Excel General
    Replies: 2
    Last Post: 01-01-2016, 09:18 PM
  3. Sorting on duplicate values (Conditional Formatting)
    By davecut85 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 01-15-2015, 06:01 PM
  4. [SOLVED] Help with Conditional Formatting Duplicate Values
    By alcharbonneau in forum Excel General
    Replies: 6
    Last Post: 02-26-2013, 09:09 PM
  5. Conditional formatting for duplicate values
    By kris26 in forum Excel - New Users/Basics
    Replies: 12
    Last Post: 03-21-2012, 06:51 AM
  6. Ignore Duplicate Values In Conditional Formatting
    By mightyeskimo in forum Excel General
    Replies: 13
    Last Post: 09-18-2010, 01:28 PM
  7. Conditional Formatting- Highlight Duplicate Values
    By Christopher_1 in forum Excel General
    Replies: 4
    Last Post: 04-21-2010, 11:02 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