+ Reply to Thread
Results 1 to 3 of 3

Lock cells based on response from another - give drop down list

  1. #1
    Forum Contributor
    Join Date
    08-16-2012
    Location
    Sefton
    MS-Off Ver
    MS Office 365 ProPlus
    Posts
    131

    Lock cells based on response from another - give drop down list

    I've got a spreadsheet where if -A1 = Y- I want B1 to have a drop down list
    If -A1 = N- I want B1 to be locked

    So far i've got data validation that will lock and unlock B1, but when it's unlocked it's just a text entry box and i don't want that. I want specific entry choices.

    1. Select B1
    2. Click on Data > Validation
    3. Allow: Custom
    4. Formula: =$A$1="Y"

    Can this be done? I can think of a way i can get a similar result with conditional formatting, but locking the cell would be better because the people who use the spreadsheet aren't the most competent and having the cell locked will prevent more mistakes than simply changing the colour

  2. #2
    Registered User
    Join Date
    12-20-2013
    Location
    Malta
    MS-Off Ver
    Excel 2010
    Posts
    12

    Re: Lock cells based on response from another - give drop down list

    I think you need a Macro to do that. Perhaps, you should seek help in http://www.excelforum.com/excel-programming-vba-macros/

  3. #3
    Forum Contributor
    Join Date
    08-16-2012
    Location
    Sefton
    MS-Off Ver
    MS Office 365 ProPlus
    Posts
    131

    Re: Lock cells based on response from another - give drop down list

    After a lot of searching and Trial and Error, i think i've worked it out. Rather than selecting custom, i select list in B1 and input a formula where if -A1 = Y- it gives one set of results to choose from in B1, but if -A1 = N- then you get a different set of results to chose from (i.e. none), then set up an error alert if they try and input anything into those cells not available in the drop down lists.

    Edit
    Ok, for some reason the error's stopped working now. It was working initially

    Edit2
    Looks like i've got it working the way i initially wanted.

    Validation in B1
    =IF($A$1="N",FALSE,LIST) - list being the list of options i want available (which has been set up on a different tab).
    If A1=Y then B1 will have the list, but if A1=N then there's no options available. I can then add the Stop Error Alert (with the Warning and Information alerts the value can be left in the cell even when incorrect).

    NOTE: A1 must be set to 'Y' to edit the data validation in B1 or you will receive an error when trying to accept any changes you make;
    The list source must be a delimited list, or a reference to single row or column
    Last edited by DHFE; 01-10-2014 at 07:15 AM.

+ 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. Drop down list with conditionnal value based on cells value
    By Warluck in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 01-17-2013, 01:37 AM
  2. [SOLVED] Un/Hidding Cells based upon drop down list
    By Kramxel in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 04-24-2012, 03:41 AM
  3. Replies: 0
    Last Post: 05-27-2011, 12:01 PM
  4. How to lock the 1st drop down list
    By excelgreen in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 04-21-2011, 07:08 PM
  5. Drop-down list and capture response
    By cycle_simon in forum Excel General
    Replies: 6
    Last Post: 12-07-2007, 04:05 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