Results 1 to 12 of 12

data validation not working while we paste the values (for removing duplicates in a column

Threaded View

  1. #5
    Forum Expert
    Join Date
    04-01-2013
    Location
    East Auckland
    MS-Off Ver
    Excel 365
    Posts
    1,347

    Re: data validation not working while we paste the values (for removing duplicates in a co

    I suppose you could then recheck the validation with a macro after pasting.

    Sub Checkval()
    '
    Dim testcell As String
    Dim lr As Integer
    lr = Cells(Rows.Count, "D").End(xlUp).Row
    'just do the used rows in D
    
    For i = 1 To lr
    
    testcell = ActiveSheet.Cells(i, 4).Address
    
    CheckValidation = Range(testcell).Validation.Value
    
    If CheckValidation = False Then
    
    MsgBox "fix validation in " & testcell
    'or clear the cell or do something
    
    Else
    End If
    Next i
    End Sub
    Last edited by scottiex; 01-27-2015 at 11:48 PM.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Sorting based on one column values and removing duplicates!
    By devpp in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 08-26-2013, 09:41 AM
  2. [SOLVED] Removing Duplicates based on column values and criteria
    By viduran88 in forum Excel General
    Replies: 9
    Last Post: 04-04-2013, 11:37 AM
  3. Removing Duplicates in one column and summarizing data
    By guard23 in forum Excel General
    Replies: 5
    Last Post: 02-09-2012, 03:33 PM
  4. validation rules not working when someone copy paste data on validation cell
    By jthakrar in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 05-17-2010, 03:36 AM
  5. merge data from array without removing column duplicates
    By aversluis in forum Excel General
    Replies: 3
    Last Post: 09-26-2007, 12:48 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