+ Reply to Thread
Results 1 to 2 of 2

Only Allow Copy Paste for Cells with Data Validation

  1. #1
    Registered User
    Join Date
    08-18-2013
    Location
    philippines
    MS-Off Ver
    Excel 2007
    Posts
    6

    Only Allow Copy Paste for Cells with Data Validation

    Hi Everyone,

    I found this macro which allows me to only allow copy-paste values in order for data validation to work. However, this is only one cell. How can i convert to make it work for a range of cells?

    Please Login or Register  to view this content.
    I tried changing the code

    Please Login or Register  to view this content.
    to

    Please Login or Register  to view this content.
    but I'm getting the message Application-defined or object-defined error. Could anyone please help me how i can rewrite the code?

  2. #2
    Forum Expert
    Join Date
    02-11-2014
    Location
    New York
    MS-Off Ver
    Excel 365 (Windows)
    Posts
    5,937

    Re: Only Allow Copy Paste for Cells with Data Validation

    Your code, and its modification, worked for me - make sure that your named range DVLists exists and is named exactly that, and that it is in the codemodule of the worksheet with that named range. (Event code does not go into standard codemodules...)
    Bernie Deitrick
    Excel MVP 2000-2010

+ 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. Prevent copy and paste invalid data for data validation cells
    By inoka in forum Excel Programming / VBA / Macros
    Replies: 14
    Last Post: 05-04-2018, 04:15 AM
  2. Allow to copy and paste only valid data over data validation cells
    By inoka in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-09-2018, 04:55 AM
  3. Allow to copy and paste only valid data over data validation cells
    By inoka in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-09-2018, 03:36 AM
  4. Copy & paste with data validation
    By egarla in forum Excel General
    Replies: 1
    Last Post: 08-19-2014, 12:55 PM
  5. [SOLVED] change validation list value and copy and paste from dependent cells
    By j.farr3ll in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 06-13-2014, 06:30 AM
  6. [SOLVED] Protect Data Validation cells from Copy Paste
    By amotto11 in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 05-09-2012, 05:06 PM
  7. 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

Tags for this Thread

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