+ Reply to Thread
Results 1 to 5 of 5

get rid of blank options in pull down from merged cells

  1. #1
    Forum Contributor
    Join Date
    08-12-2012
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    163

    get rid of blank options in pull down from merged cells

    i have a list of items and a active x combo box that has the list of the items. the problem is that i have some items that merge multiple rows together depending on how many sizes there are for that item.
    so say my list starts at B4 and B4 &B5 are merged together in the drop down bar there will be the item name than a blank space under it do to the cells being merged
    this is the code

    Please Login or Register  to view this content.
    how do i change the list to get rid of the blank spaces in the pull down do to merged cells? is this possible?

    thanks
    JED

  2. #2
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258

    Re: get rid of blank options in pull down from merged cells

    Hello jed38,

    Is this ComboBox on a worksheet or VBA UserForm?
    Sincerely,
    Leith Ross

    Remember To Do the Following....

    1. Use code tags. Place [CODE] before the first line of code and [/CODE] after the last line of code.
    2. Thank those who have helped you by clicking the Star below the post.
    3. Please mark your post [SOLVED] if it has been answered satisfactorily.


    Old Scottish Proverb...
    Luathaid gu deanamh maille! (Rushing causes delays!)

  3. #3
    Forum Contributor
    Join Date
    08-12-2012
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    163

    Re: get rid of blank options in pull down from merged cells

    its a combobox on a worksheet that is the code that brings up the list. it just has alot of spaces from merged cells

  4. #4
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258

    Re: get rid of blank options in pull down from merged cells

    Hello jed38,

    This macro worked for me. Try it on your system and let me know the results.
    Please Login or Register  to view this content.

  5. #5
    Forum Contributor
    Join Date
    08-12-2012
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    163

    Re: get rid of blank options in pull down from merged cells

    i tried it and it said run time error '70'
    Permission denied

    i hit debug and it highlighted the second last line in the code "ComboBox1.List=NewList"

    the only thing i changed was the range to be B4:100
    heres the code i put in
    Please Login or Register  to view this content.

+ 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