+ Reply to Thread
Results 1 to 3 of 3

Protected and locked after the data entry

  1. #1
    Registered User
    Join Date
    12-03-2012
    Location
    London, England
    MS-Off Ver
    Excel 2007
    Posts
    2

    Protected and locked after the data entry

    Hi guys, I'm new in Excel VBA coding, I would like to make the data unchangeable after save. And now I need to create a macro that the cell will be protected and locked after the data entry. Only some of the cell can be enter the data while most of other cell have been protected and locked already. Please help me....

  2. #2
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,462

    Re: Protected and locked after the data entry

    You would need to use VBA to do that. You'd have a Worksheet Change event monitoring the cells of interest and, after the data has been entered, you'd have to set the status of the cell to "locked". For that to work, the sheet would have to be protected.

    Sounds a bit dangerous though. It assumes that the correct data will be entered first time ... there will be no opportunity to change it.


    Regards, TMS
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  3. #3
    Registered User
    Join Date
    12-03-2012
    Location
    London, England
    MS-Off Ver
    Excel 2007
    Posts
    2

    Re: Protected and locked after the data entry

    Thanks for the reply~ . However, its that possible to be done through VBA code.

    Actually my condition is like this. I have a template which has text in some cells and some cells are blank, i have lock the cells which has text and keep the blank cells unlocked for user input. After the user input, i need to lock also the cell which the data have been entered. Its that possible?

+ 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