+ Reply to Thread
Results 1 to 31 of 31

Dropdown List Within One Cell

  1. #1
    Forum Contributor
    Join Date
    03-26-2021
    Location
    California, US
    MS-Off Ver
    MS Office 2010
    Posts
    109

    Dropdown List Within One Cell

    Friends!

    Is there any way I could create a dropdown list within one cell (without having to select a range of cells to create a dropdown list)

    Now, this particular cell should have the ability to extend if new data is entered into it.

    For example, I will enter a name, say, Apple.

    The dropdown list should be Apple only.

    Now, I will add, say, Orange, Banana, or Kiwi.

    If I open the dropdown list it should show all these in it.

    Now, again, this should be done within one cell and without having to select a range of cells in order to create this list.

    I hope I am explaining thoroughly and I really hope someone could help me out, please.

  2. #2
    Forum Expert Roel Jongman's Avatar
    Join Date
    03-28-2015
    Location
    Netherlands
    MS-Off Ver
    Office 365
    Posts
    1,494

    Re: Dropdown List Within One Cell

    there is the option to put a comma separated list in the datavalidation setup instead of using a range.

  3. #3
    Forum Contributor
    Join Date
    03-26-2021
    Location
    California, US
    MS-Off Ver
    MS Office 2010
    Posts
    109

    Re: Dropdown List Within One Cell

    Yes, that one I know but that person doesn't know for whom I am creating this list for.

    That person wants to type in the cell instead of going to Data Validation.

  4. #4
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2504 (Windows 11 Home 24H2 64-bit)
    Posts
    90,935

    Re: Dropdown List Within One Cell

    Are you (and they) still using Excel 2010? If not, what?
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help. It's a universal courtesy.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    NB:
    as a Moderator, I never accept friendship requests.
    Forum Rules (updated August 2023): please read them here.

  5. #5
    Forum Contributor
    Join Date
    03-26-2021
    Location
    California, US
    MS-Off Ver
    MS Office 2010
    Posts
    109

    Re: Dropdown List Within One Cell

    We, in our "organization", all use MS Excel 2010. =)

  6. #6
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2504 (Windows 11 Home 24H2 64-bit)
    Posts
    90,935

    Re: Dropdown List Within One Cell

    What a pain!

    I think you are going to need to use a hidden helper column or row somewhere if you want to avoid VBA for this.

  7. #7
    Forum Contributor
    Join Date
    03-26-2021
    Location
    California, US
    MS-Off Ver
    MS Office 2010
    Posts
    109

    Re: Dropdown List Within One Cell

    I am willing to take chances with VBA but no helper cells, please.

  8. #8
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2504 (Windows 11 Home 24H2 64-bit)
    Posts
    90,935

    Re: Dropdown List Within One Cell

    OK - I'm moving this to the VBA section.

  9. #9
    Registered User
    Join Date
    03-12-2022
    Location
    Argentina
    MS-Off Ver
    2016
    Posts
    38

    Re: Dropdown List Within One Cell

    Hi,
    A dropdown list needs a list , this list could be words comma separated in one cell.
    like the example below,

    validationwithonecell.xlsm

  10. #10
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2504 (Windows 11 Home 24H2 64-bit)
    Posts
    90,935

    Re: Dropdown List Within One Cell

    You've hard-coded the list in the DV rule - that's not what the OP wants.

  11. #11
    Forum Expert
    Join Date
    07-20-2011
    Location
    Mysore, India.
    MS-Off Ver
    Excel 2019
    Posts
    8,710

    Re: Dropdown List Within One Cell

    Worksheet event is used. Range for validation is A2:A1000, can be changed.
    Please Login or Register  to view this content.
    How to use workheet event the code
    Right click on Sheet tab --> view code
    Visual Basic (VB) window opens.
    Paste the code
    Close the VB window.
    Save the file as .xlsm
    Attached Files Attached Files
    Pl note
    Array formula should be confirmed with Ctrl+Shift+Enter keys together.
    If answere is satisfactory press * to add reputation.

  12. #12
    Forum Contributor
    Join Date
    03-26-2021
    Location
    California, US
    MS-Off Ver
    MS Office 2010
    Posts
    109

    Re: Dropdown List Within One Cell

    Thank you for your time and reply.

    I might be missing something because the file, what it's intended for, does not really serve the purpose.

    I mean, it's just a couple of lists that are created through data validation.

    Also, when I add anything to the yellow highlighted cell, none of the dropdown lists correspond to it.

    The red coloured box does not allow me to add anything to it.

    I might have explained myself not precisely.

    What I am in need of is whenever I add something to a cell, any cell, the cell should convert itself into a dropdown list. As I proceed to add further names or values into it, the dropdown list should expand and allow further to add more items into it.

    I am not looking for any helper cell or any other cell that I might have to fill-in in order for the original cell (dropdown list cell) to correspond or expand.

    Please.

    But thank you to anyone who has taken the time to reply and help, really.

  13. #13
    Forum Guru
    Join Date
    08-15-2004
    Location
    Tokyo, Japan
    MS-Off Ver
    2013 O.365
    Posts
    22,834

    Re: Dropdown List Within One Cell

    AFAIK, the limit of Validation formula for 2010 is 256 characters. (so, not many)

    To worksheet code module
    Change [a2] to suite like [a1] or [a2:a10] etc.
    Please Login or Register  to view this content.
    Last edited by jindon; 03-10-2024 at 02:55 AM.

  14. #14
    Forum Expert
    Join Date
    07-20-2011
    Location
    Mysore, India.
    MS-Off Ver
    Excel 2019
    Posts
    8,710

    Re: Dropdown List Within One Cell

    For cell C2. Worksheet event is used.
    Please Login or Register  to view this content.
    Attached Files Attached Files

  15. #15
    Forum Contributor
    Join Date
    03-26-2021
    Location
    California, US
    MS-Off Ver
    MS Office 2010
    Posts
    109

    Re: Dropdown List Within One Cell

    @jindon

    Could you please put it into an Excel file for me to use?
    Last edited by AliGW; 03-10-2024 at 04:05 AM. Reason: Please don't quote unnecessarily - use the Quick Reply button instead.

  16. #16
    Forum Contributor
    Join Date
    03-26-2021
    Location
    California, US
    MS-Off Ver
    MS Office 2010
    Posts
    109

    Re: Dropdown List Within One Cell

    @kvsrinivasamurthy

    This looks almost as I have wanted it to be.

    Although, the Yellow Highlighted Box/Cell is doing the right thing, I don't want all the Text or Value to be shown on the cell. Only the Text/Value should be shown whatever and whenever I want to select from the dropdown list.

    Also, I don't really understand the purpose of that Red Box Data Validation Cell. Could I delete it and still use the file without any issues?
    Last edited by AliGW; 03-10-2024 at 04:08 AM. Reason: Please don't quote unnecessarily - use the Quick Reply button instead.

  17. #17
    Forum Guru
    Join Date
    08-15-2004
    Location
    Tokyo, Japan
    MS-Off Ver
    2013 O.365
    Posts
    22,834

    Re: Dropdown List Within One Cell

    Enter something in A2.
    Attached Files Attached Files

  18. #18
    Forum Contributor
    Join Date
    03-26-2021
    Location
    California, US
    MS-Off Ver
    MS Office 2010
    Posts
    109

    Re: Dropdown List Within One Cell

    This is perfect!

    But!

    We are almost there, though.

    How do I delete an item from the list because it doesn't work when I delete something from the list.

    Also, just to make things more complicated but really delightful for me, suppose, I would like to create one or more dependent cells corresponding to what you have just created.

    Say, Apple is entered into the dropdown list, a message should pop-up and request to enter the Price for it, that price will be entered automatically next to this cell.

    Once the price is entered, another message should pop-up and request for Colour.

    And so on.

    Also, once an item from the original dropdown list is deleted, so too will these dependent cells clear out.

    I hope you understand and get the idea.

    I really and sincerely hope that it isn't an extra condition to the original query but it's really required and would mean the world to me.

    Otherwise, I will close the thread as solved.

    But please.

  19. #19
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2504 (Windows 11 Home 24H2 64-bit)
    Posts
    90,935

    Re: Dropdown List Within One Cell

    No need to start a new thread, but in future, please state all objectives in the opening post to avoid thread creep. Thanks.

  20. #20
    Forum Contributor
    Join Date
    03-26-2021
    Location
    California, US
    MS-Off Ver
    MS Office 2010
    Posts
    109

    Re: Dropdown List Within One Cell

    My sincerest apologies.

    To be honest, it really just came to my mind that this is also very much required as the original query.

    Again, my apologies.

  21. #21
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2504 (Windows 11 Home 24H2 64-bit)
    Posts
    90,935

    Re: Dropdown List Within One Cell

    OK - no worries.

  22. #22
    Forum Guru
    Join Date
    08-15-2004
    Location
    Tokyo, Japan
    MS-Off Ver
    2013 O.365
    Posts
    22,834

    Re: Dropdown List Within One Cell

    I wrote the code according to your opening post.

    Show us some visual examples with before/after in each step in the workbook.

  23. #23
    Forum Contributor
    Join Date
    03-26-2021
    Location
    California, US
    MS-Off Ver
    MS Office 2010
    Posts
    109

    Re: Dropdown List Within One Cell

    Please see attached.

    Example of Prices and Colours are given in Column E, F, and G.

    Again, these are just examples and will be deleted and will not be used.

    Prices and Colours will be entered as per whatever a user enters.

    Also, if a user deletes an item from the original dropdown list, all dependent cells, such as, Prices and Colours, will clear out too.

    I hope this helps.

    And again, thank you very much for your time and help and please accept my apologies for the mess.
    Attached Files Attached Files

  24. #24
    Forum Guru
    Join Date
    08-15-2004
    Location
    Tokyo, Japan
    MS-Off Ver
    2013 O.365
    Posts
    22,834

    Re: Dropdown List Within One Cell

    See if this is how you wanted.
    Please Login or Register  to view this content.
    Attached Files Attached Files

  25. #25
    Forum Contributor
    Join Date
    03-26-2021
    Location
    California, US
    MS-Off Ver
    MS Office 2010
    Posts
    109

    Re: Dropdown List Within One Cell

    Yes, a road to perfection.

    Here is the thing though, say, I enter Apple, it does ask me all the things that are required, however, whenever I cancel any of the dialogue box, the Apple stays. It should disappear because the process of entering all the details required is not completed and was abandoned midway.

    Also, say, Apple's details are correctly entered, and then, I entered Orange and all its related details. If I go back to Apple and select it from the dropdown list, all the dependent cells should release its corresponding details in regard to Apple but it doesn't.

    Also, a user shouldn't be able to delete or amend any of the Prices or Colours without having to delete Apple first.

  26. #26
    Forum Guru
    Join Date
    08-15-2004
    Location
    Tokyo, Japan
    MS-Off Ver
    2013 O.365
    Posts
    22,834

    Re: Dropdown List Within One Cell

    Try the attached.
    Attached Files Attached Files

  27. #27
    Forum Contributor
    Join Date
    03-26-2021
    Location
    California, US
    MS-Off Ver
    MS Office 2010
    Posts
    109

    Re: Dropdown List Within One Cell

    Yes, again, whenever I select back the Apple from the dropdown list, its related details such as the Price and Colour are not shown, instead it asks me to enter the details of Price and Colour all over again.

    Also, when I delete either Apple's Price or Colour, the Apple is not affected, it should be deleted too as it serves no purpose without the Price and/or Colour.

    But otherwise the abandoning midway thing is perfect!

  28. #28
    Forum Expert
    Join Date
    07-20-2011
    Location
    Mysore, India.
    MS-Off Ver
    Excel 2019
    Posts
    8,710

    Re: Dropdown List Within One Cell

    Post deleted.
    Last edited by kvsrinivasamurthy; 03-10-2024 at 07:17 AM.

  29. #29
    Forum Guru
    Join Date
    08-15-2004
    Location
    Tokyo, Japan
    MS-Off Ver
    2013 O.365
    Posts
    22,834

    Re: Dropdown List Within One Cell

    The you will need to store the data history in somewhere on the sheet.
    So, now validation list has no limit.
    Added a sheet named "MyList" and it is hidden.
    Attached Files Attached Files
    Last edited by jindon; 03-10-2024 at 07:44 AM. Reason: File has been replaced.

  30. #30
    Forum Contributor
    Join Date
    03-26-2021
    Location
    California, US
    MS-Off Ver
    MS Office 2010
    Posts
    109

    Re: Dropdown List Within One Cell

    This is pure solid perfection, my Sir! :o

    I salute you!

    Thank you so very much!

  31. #31
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2504 (Windows 11 Home 24H2 64-bit)
    Posts
    90,935

    Re: Dropdown List Within One Cell

    If you have not already done so, remember that you can reward anyone who offered you help towards a solution for your issue by clicking the small star icon (* Add Reputation) located in the lower left corner of the post in which the help was given. By doing so you can add to the reputation(s) of each of those who offered help.

+ 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. Replies: 6
    Last Post: 01-20-2024, 08:32 PM
  2. Replies: 1
    Last Post: 10-14-2021, 11:47 AM
  3. Replies: 6
    Last Post: 02-02-2016, 04:26 PM
  4. Replies: 3
    Last Post: 11-13-2015, 05:10 AM
  5. Replies: 0
    Last Post: 08-22-2012, 03:52 PM
  6. Replies: 21
    Last Post: 12-02-2009, 03:27 PM
  7. Date dropdown list and a Time dropdown list in outlook
    By L_ter in forum Outlook Programming / VBA / Macros
    Replies: 3
    Last Post: 03-30-2009, 02:33 AM

Tags for this Thread

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