+ Reply to Thread
Results 1 to 8 of 8

Excel 2007 : Combobox works with On sheet data validation list but not Off Sheet list

  1. #1
    Registered User
    Join Date
    07-01-2010
    Location
    Paris, VA
    MS-Off Ver
    Excel 2007
    Posts
    17

    Combobox works with On sheet data validation list but not Off Sheet list

    Attached is an example that I pulled from Contextures website (Grovier). There a re 3 sheets. The first sheet if the original file and all works as it should, In which the combobox attaches itself to the active cell containing data validation using one click. The lists for the data validation are contained on the same sheet.

    Sheet Two: is the same thing modified such that the data validation lists (moved to sheet List) are using the named Ranges of the lists offsheet. Most of the functionality of the combobox no longer works. Namely the font change , number of items the list dispplays on click, autocomplete dont work any more.

    any thoughts?
    Attached Files Attached Files

  2. #2
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Combobox works with On sheet data validation list but not Off Sheet list

    When I removed your BeforeDoubleClick macro and put the code that was in it into your SelectionChange macro, it seemed to work...also had to correct the "Lists" reference.
    Please Login or Register  to view this content.
    _________________
    Microsoft MVP 2010 - Excel
    Visit: Jerry Beaucaire's Excel Files & Macros

    If you've been given good help, use the icon below to give reputation feedback, it is appreciated.
    Always put your code between code tags. [CODE] your code here [/CODE]

    ?None of us is as good as all of us? - Ray Kroc
    ?Actually, I *am* a rocket scientist.? - JB (little ones count!)

  3. #3
    Registered User
    Join Date
    07-01-2010
    Location
    Paris, VA
    MS-Off Ver
    Excel 2007
    Posts
    17

    Re: Combobox works with On sheet data validation list but not Off Sheet list

    JB,

    Thanks for pointing out the need to declare to the wcLists variable, I missed that.

    The Macro you removed is an important component that would facilitate natural keyboard data entry without having to use the mouse to "Click" on the next cell. In that, it functions in the Original Sheet to move the combo-box upon the use of a Tab or Enter to the next cell.

    Can you see what is preventing that Macro from performing as it should once the data validation lists have been moved to another sheet. (At least that is what appears to have been the culprit in breaking the Macro)

  4. #4
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Combobox works with On sheet data validation list but not Off Sheet list

    Then I guess you've lost me. I took out that macro and put in the one shown above and now sheet2 is behaving the same way. If I click by mouse the ComboBox appears and if I finish by pressing ALT or ENTER, the box appears in the next cell.

  5. #5
    Registered User
    Join Date
    07-01-2010
    Location
    Paris, VA
    MS-Off Ver
    Excel 2007
    Posts
    17

    Re: Combobox works with On sheet data validation list but not Off Sheet list

    Hmmmm. Would you kindly send me your file. I've just retried it and neither Alt, Tab or Enter moves me into the next cell. Not sure what the difference is.

    Thanks in advance for your help.

  6. #6
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Combobox works with On sheet data validation list but not Off Sheet list

    Here you go...
    Attached Files Attached Files

  7. #7
    Registered User
    Join Date
    07-01-2010
    Location
    Paris, VA
    MS-Off Ver
    Excel 2007
    Posts
    17

    Re: Combobox works with On sheet data validation list but not Off Sheet list

    Thanks again JB. I see that with the macro at the bottom it works for that sheet. Excitedly, I adapted it to my own application and it fails. No idea why. It's all seems pretty straightforward.

  8. #8
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Combobox works with On sheet data validation list but not Off Sheet list

    Yeah, this stuff can be frustrating, though I like the technique you've implemented. Very interesting stuff.

+ 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