+ Reply to Thread
Results 1 to 3 of 3

How to allow user paste(Ctrl + V) a row to protected sheet(some columns are locked)

  1. #1
    Registered User
    Join Date
    07-29-2008
    Location
    China
    Posts
    3

    How to allow user paste(Ctrl + V) a row to protected sheet(some columns are locked)

    Hi, guys
    I want to allow user copy(Ctrl + C) and paste(Ctrl + V) a row.
    because some columns are locked and the sheet is protected.
    so, when user doing so, a warning dialog is show and can't do the paste.

    so, I want to make it available in code.
    what I want to do is add some codes in this function:

    Please Login or Register  to view this content.
    and in Worksheet_Change function, I protect the sheet again.

    But I find that when I do Sheet1.Unprotect , the clipboard is empty!!!
    I just want to allow user can copy and paste a row, the locked cell's value can be ignored.
    But I can't find a good solution.
    Any help?

    Thanks in advance.

  2. #2
    Forum Contributor
    Join Date
    06-14-2008
    Posts
    153
    Hi

    In your case you test CutCopyMode for xlCopy as follows:
    Please Login or Register  to view this content.
    Please retry.
    Welcome to: http://www.exceldigest.com/myblog/
    "Excel help for the rest of us"

  3. #3
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200
    openSuSe, please reade the Forum Rules & stick to the original post until solved!
    Hope that helps.

    RoyUK
    --------
    For Excel Tips & Solutions, free examples and tutorials why not check out my web site

    Free DataBaseForm example

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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