+ Reply to Thread
Results 1 to 4 of 4

RowSource Not Populating ComboBox

  1. #1
    Forum Contributor
    Join Date
    06-15-2009
    Location
    Ontario, canada
    MS-Off Ver
    Office 365
    Posts
    371

    RowSource Not Populating ComboBox

    What might be preventing my combobox from populating with this code that sets it's rowsource?

    Please Login or Register  to view this content.
    This code does not leave me with any errors, but it also does not populate the combobox with the defined rowsource.

    Worksheet "LISTS" does exist, and the appropriate data is in the respective range.
    Now, the workbook that LISTS resides in is second of three open workbooks part of my application, which is hidden. This code is in the same workbook as LISTS.

  2. #2
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: RowSource Not Populating ComboBox

    Hi

    Try code like

    Please Login or Register  to view this content.
    Lists!B36:B40 is the way Excel refers to a sheet and range not the way VBA refers.
    As an aside it's better practice to use the VBA sheet code name not the tab name. Tab names are too easily changed and a macro which relies on that will fall over if a sheet tab name is changed

    Hence it's preferable to use code like
    Please Login or Register  to view this content.
    where 'Sheet1' is the VBA code name, In the Project Window you'd see this as Sheet1(Lists)
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  3. #3
    Forum Contributor
    Join Date
    06-15-2009
    Location
    Ontario, canada
    MS-Off Ver
    Office 365
    Posts
    371

    Re: RowSource Not Populating ComboBox

    Thank you Richard. This seems a much better option. Thanks also for the advice!

  4. #4
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: RowSource Not Populating ComboBox

    My pleasure and thanks for the rep.

+ 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. [SOLVED] Use RowSource in ComboBox
    By Len Silva in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 06-11-2017, 09:20 AM
  2. [SOLVED] Userform combobox to populate RowSource for new values in combobox
    By Stratfordoaks in forum Excel Programming / VBA / Macros
    Replies: 14
    Last Post: 12-17-2013, 01:18 PM
  3. [SOLVED] Combobox value defines Combobox Rowsource
    By onmyway in forum Excel Programming / VBA / Macros
    Replies: 14
    Last Post: 09-03-2013, 08:57 AM
  4. [SOLVED] Add RowSource to Userform ComboBox based on value on Another ComboBox
    By Baziwan in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 10-10-2012, 01:17 PM
  5. Way to populate combobox rowsource based on previous combobox value
    By subbby in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 09-08-2012, 12:50 AM
  6. Combobox: How to determine the location of the selected item if combobox has rowsource
    By ahsanzafar in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-11-2012, 03:24 PM
  7. Combobox rowsource
    By mike0123m in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-10-2009, 02:46 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