+ Reply to Thread
Results 1 to 6 of 6

How do I lock cells once data input

  1. #1
    Forum Contributor
    Join Date
    08-02-2005
    Location
    LONDON
    MS-Off Ver
    OFFICE365
    Posts
    140

    How do I lock cells once data input

    Hi

    I have a workbook that has unprotected cells that people has to put data into.

    What im trying to do is when data is input by someone I need the cell protected so it cannot be changed until the sheet is printed via a macro. Once printed I have a clear cells macro of which I then need to unprotect and clear cells.

    Any Ideas as sont know where to start and programming skills very low.

  2. #2
    Valued Forum Contributor
    Join Date
    05-15-2017
    Location
    US
    MS-Off Ver
    365
    Posts
    868

    Re: How do I lock cells once data input

    You would need to have some routine to determine if the cell has been updated..
    then you can do this:

    Please Login or Register  to view this content.
    If you had a sample file, others could chime in and assist.

  3. #3
    Forum Contributor
    Join Date
    08-02-2005
    Location
    LONDON
    MS-Off Ver
    OFFICE365
    Posts
    140

    Re: How do I lock cells once data input

    Sorry how would I do routine to determine if the cell has been updated?

  4. #4
    Valued Forum Contributor
    Join Date
    05-15-2017
    Location
    US
    MS-Off Ver
    365
    Posts
    868

    Re: How do I lock cells once data input

    https://docs.microsoft.com/en-us/off...rksheet.change

    Occurs when cells on the worksheet are changed by the user or by an external link.

  5. #5
    Forum Contributor
    Join Date
    08-02-2005
    Location
    LONDON
    MS-Off Ver
    OFFICE365
    Posts
    140

    Re: How do I lock cells once data input

    Many thanks.

    Can I just check that this would be OK for a macro...

    Please Login or Register  to view this content.
    If so do you know what the number is to turn cells yellow.

  6. #6
    Valued Forum Contributor
    Join Date
    05-15-2017
    Location
    US
    MS-Off Ver
    365
    Posts
    868

    Re: How do I lock cells once data input

    dont know the color codes, but you can always "record" a macro and see what it records when you change a cell color..

    The recorder helps me when i dont know or cant find anything online..

    start recording, change a cell color, then stop the recorder, then go look at the macro it generated and see what the code is.

+ 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. Lock cells after input and after entering value
    By Medicius in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 12-16-2015, 03:13 AM
  2. Protect/Lock Cells after Data Input
    By Ashraf1 in forum Excel General
    Replies: 11
    Last Post: 08-27-2014, 04:23 AM
  3. Protect/Lock Cells after Data Input
    By Ladygoodtime in forum Excel General
    Replies: 1
    Last Post: 03-15-2013, 04:55 PM
  4. Cells lock after user input - based on data
    By francis.rizzo in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 10-12-2012, 09:55 AM
  5. lock cells when input data into certain cells
    By helene58 in forum Excel General
    Replies: 1
    Last Post: 02-17-2012, 11:55 AM
  6. Lock cells for input if dat has passed
    By Hornet75 in forum Excel General
    Replies: 6
    Last Post: 11-09-2011, 09:50 AM
  7. Lock cells in a row after input
    By nanogr in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-01-2011, 06:07 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