+ Reply to Thread
Results 1 to 2 of 2

Excel 2007 : Lock a cell based on a previous selection

Hybrid View

  1. #1
    Registered User
    Join Date
    05-05-2010
    Location
    Maidenhead, England
    MS-Off Ver
    Excel 2007
    Posts
    39

    Lock a cell based on a previous selection

    hi all,

    I have an overtime sheet which I am developing.

    In column a, there is data validation so they can pick 'On Call', 'Working' and now 'Early Shift'.

    Column D is for time entry. However if they select Early Shift, I do not need to record the time, so would like the cell on the corresponding row in columnn D to become locked and change colour to show it does not require entry.

    how could I do this?

    Thanks a lot in advance

  2. #2
    Forum Expert Palmetto's Avatar
    Join Date
    04-04-2007
    Location
    South Eastern, USA
    MS-Off Ver
    XP, 2007, 2010
    Posts
    3,978

    Re: Lock a cell based on a previous selection

    I generally opt for using a helper cell in these situations and use Data validation with the Custom Option to check the helper cell.

    Helper cell contains a formula; =A1="Early Shift"
    It returns either True or False

    In column-D cells using data validation, custom option and this formula:
    =G1=TRUE (adjust cell reference, obviously)

    If G1 = False, data validation with errror alert set to Stop will prevent data entry. Customize the alert message as required.

    You could also use the above formula in a Conditional Format to change the cell color to highlight the cell when entries are required or not.
    Palmetto

    Do you know . . . ?

    You can leave feedback and add to the reputation of all who contributed a helpful response to your solution by clicking the star icon located at the left in one of their post in this thread.

+ 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