+ Reply to Thread
Results 1 to 4 of 4

Listboxes display headers and not populating defined range

  1. #1
    Forum Contributor
    Join Date
    02-25-2013
    Location
    Colorado, US
    MS-Off Ver
    Microsoft 365 Apps
    Posts
    518

    Listboxes display headers and not populating defined range

    So just going along creating my userforms. Everything was populating in my listboxes just fine. Dropdown was working correctly. I decided to change the userform names (for simplification purposes) in the Properties window. I reflected that change in the command scripts. My first problem was that it kept erroring on the userform.show lines (with userform = respective form). I missed something in the module, but corrected that. The forms all load properly now, however now the listboxes are all screwed up.

    My Input form now displays 4 columns and headers, when it has only been displaying 3 columns (no ID column) and no headers before the name was changed.

    My Tops form is completely blank when it was displaying 3 columns with no headers before the name change. When I do an execute Save, the listbox pops up in the Tops form. If I close it and reopen it again, the listbox is again blank.

    Also, my dropdown is no longer populating the range I'm pointing it to. Can someone see anything I'm overlooking here. I haven't done anything to the code prior to this pileup. The basic form loading and listbox display were working perfectly until I changed the name of the forms. Did I totally corrupt this thing? Please help??? I've attached orkbook attached.
    Attached Files Attached Files
    Last edited by terriertrip; 07-06-2017 at 04:36 PM.

  2. #2
    Forum Guru bakerman2's Avatar
    Join Date
    10-03-2012
    Location
    Antwerp, Belgium
    MS-Off Ver
    MO Prof Plus 2016
    Posts
    6,907

    Re: Listboxes display headers and not populating defined range

    Change frmInput_Initialize to UserForm_Initialize.
    Same goes for form Tops.
    Avoid using Select, Selection and Activate in your code. Use With ... End With instead.
    You can show your appreciation for those that have helped you by clicking the * at the bottom left of any of their posts.

  3. #3
    Forum Contributor
    Join Date
    02-25-2013
    Location
    Colorado, US
    MS-Off Ver
    Microsoft 365 Apps
    Posts
    518

    Re: Listboxes display headers and not populating defined range

    Thanks, @bakerman2. That seems to have fixed it.

  4. #4
    Forum Guru bakerman2's Avatar
    Join Date
    10-03-2012
    Location
    Antwerp, Belgium
    MS-Off Ver
    MO Prof Plus 2016
    Posts
    6,907

    Re: Listboxes display headers and not populating defined range

    You're welcome and thanks for 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] Sum Drop Lists, If Value Not Between Defined Range Display Error and Reset
    By UnreadSix in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 02-27-2014, 03:21 PM
  2. [SOLVED] Copy Columns that the headers(dates) fall within a user defined date range...
    By Zoediak in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 05-06-2013, 11:27 AM
  3. Replies: 2
    Last Post: 08-12-2011, 08:17 AM
  4. Populating Two Listboxes with Sheets Based on Cell Value & Printing Their Selection
    By TBrooker in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-14-2009, 03:45 AM
  5. Display Expense used up in user defined date range
    By Terrycos in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 11-22-2008, 10:12 AM
  6. populating your listboxes with code in 'declarations'
    By durandal05 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-12-2008, 09:11 PM
  7. populating listboxes
    By talytech in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-12-2007, 07:15 PM
  8. Populating a ComboBox with a Defined Range from another Sheet
    By Izran in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-26-2005, 10:05 AM

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