+ Reply to Thread
Results 1 to 3 of 3

How to make Userform Listbox Header Non-selectable

  1. #1
    Registered User
    Join Date
    10-14-2015
    Location
    East Coast
    MS-Off Ver
    2013
    Posts
    69

    How to make Userform Listbox Header Non-selectable

    Hi All,

    I have a multi-column userform listbox that pulls from a dynamic range. Everything works great. However, I've been told that the header of said listbox needs to be non-selectable. I'm not sure if this is even possible. See screenshot.

    Any help would be great - thanks.
    Attached Images Attached Images

  2. #2
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS365 Family 64-bit
    Posts
    24,721

    Re: How to make Userform Listbox Header Non-selectable

    I assume you are using AddItem in your code to build your listbox. How are you placing the header? Are you explicitly adding it in your code as the first row of data? If so there are two alternatives:

    1. Instead of using AddItem to build your listbox, use a range in a worksheet and assign it to attribute RowSource, and put the headers in the row just above that range, and then turn attribute ColumnHeads=True. Unselectable column headers will be shown.

    2. Instead of putting the headers in the listbox, use Labels just above the listbox.

    If this is not helpful then remove all your data then attach a copy of your file. An image attachment has limited value. The paper clip icon does not work for attachments. To attach a file, under the text box where you type your reply click the Go Advanced button. On the next screen scroll down and click on Manage Attachments, which will show a pop-up window to Select and Upload a file. Then close the window.
    Jeff
    | | |會 |會 |會 |會 | |:| | |會 |會
    Read the rules
    Use code tags to [code]enclose your code![/code]

  3. #3
    Registered User
    Join Date
    10-14-2015
    Location
    East Coast
    MS-Off Ver
    2013
    Posts
    69

    Re: How to make Userform Listbox Header Non-selectable

    6StringJazzer,

    Thanks for the quick reply, your first recommendation worked well.

+ 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. Make value field selectable
    By Jonathan9 in forum Excel Charting & Pivots
    Replies: 3
    Last Post: 07-31-2014, 01:11 AM
  2. [SOLVED] applying select case function to selectable options in listbox
    By Kwasimitsu in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 12-21-2013, 02:09 AM
  3. [SOLVED] UserForm - How To Make TextBox Value Change Depending On ListBox Selection
    By ScotyB in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 11-26-2013, 05:05 PM
  4. Userform - make sure optionbutton and listbox has values
    By Masun in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 06-04-2013, 07:40 AM
  5. [SOLVED] UserForm contains optionbuttons that generate listbox to make selection
    By jbeeball in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 05-11-2012, 09:34 PM
  6. Make only one of two cells selectable
    By Greg Jansen in forum Excel General
    Replies: 9
    Last Post: 09-07-2008, 01:43 PM
  7. [SOLVED] How do I make a line non-selectable?
    By Shinka in forum Excel General
    Replies: 4
    Last Post: 10-05-2005, 05:05 PM

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