+ Reply to Thread
Results 1 to 4 of 4

VBA: Keep worksheet unprotected but protect single cells from change/deletion?

  1. #1
    Registered User
    Join Date
    09-30-2016
    Location
    Munich, Germany
    MS-Off Ver
    2013
    Posts
    17

    VBA: Keep worksheet unprotected but protect single cells from change/deletion?

    Hello all,

    I have a user enter data into an Excel-sheet via a bar-code scanner. Once all data-sets are entered the user scans a bar-code with a "done"-signal. With this "done"-signal the just entered data should be protected against being changed or deleted.
    From what I have seen I could go in with protection of the sheet and single locked cells or with custom data-validation. However both are not really appealing, I would rather keep the sheet itself unprotected. The data-validation would also not protect from deletion.
    Is there a way without having to protect the whole sheet and setting single cells to locked?

    Cheers,

    Moadll

  2. #2
    Valued Forum Contributor
    Join Date
    12-02-2009
    Location
    Austin, Tx
    MS-Off Ver
    Office 365 64-Bit, 2108, build 14326.21018
    Posts
    4,093

    Re: VBA: Keep worksheet unprotected but protect single cells from change/deletion?

    FYI that you wouldn't have to set single cells to locked. By Default all Excel cells are locked, but locking has no effect unless the worksheet is protected. You say protecting the sheet is not appealing, but you don't say why. Did you know you can unlock all cells in the sheet at one time, and just lock a single cell or group of cells. Then, when you protect the worksheet, your folks can do whatever they want to your sheet (within the parameters you define), EXCEPT with that locked cell or region.

  3. #3
    Registered User
    Join Date
    09-30-2016
    Location
    Munich, Germany
    MS-Off Ver
    2013
    Posts
    17

    Re: VBA: Keep worksheet unprotected but protect single cells from change/deletion?

    Hello Jomilli,

    sorry for the long delay until answering, however I was pretty busy recently.
    After reading & understanding your post I stand corrected. Making the cells as protected and then protect the worksheet is actually the way to go (and works like a charm).

    Thanks!

  4. #4
    Valued Forum Contributor
    Join Date
    12-02-2009
    Location
    Austin, Tx
    MS-Off Ver
    Office 365 64-Bit, 2108, build 14326.21018
    Posts
    4,093

    Re: VBA: Keep worksheet unprotected but protect single cells from change/deletion?

    Glad to know you got it worked out. Keep Excelling!

+ 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. [SOLVED] Protect manual deletion of a worksheet
    By ArnolddG in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-14-2014, 01:09 PM
  2. [SOLVED] Macro to Protect Unprotected Cells on worksheet
    By nsmjc in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-29-2014, 06:29 AM
  3. Worksheet Change - Unprotected Property
    By daffodil11 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 09-30-2013, 03:00 PM
  4. protect sheet, not move after enter, select unprotected cells only
    By Peto in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 08-09-2009, 05:05 PM
  5. Keep Sheet Unprotected but protect some cells
    By Dave69rock in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 11-30-2008, 05:17 AM
  6. Worksheet change event not responding to cell deletion
    By jman0707 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 11-14-2008, 06:30 PM
  7. Protect worksheet from deletion
    By Richard in forum Excel General
    Replies: 1
    Last Post: 07-17-2006, 10:45 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