+ Reply to Thread
Results 1 to 7 of 7

Listbox with multi-columns what determines the order of the columns?

  1. #1
    Valued Forum Contributor jwright650's Avatar
    Join Date
    12-10-2010
    Location
    Va, USA
    MS-Off Ver
    Excel 2003, Excel 2010
    Posts
    606

    Listbox with multi-columns what determines the order of the columns?

    Userform multi-column listboxes.....what determines where the data will show up in the listbox(ie which column)?

    If you take a peek at SearchInventory userform....run it and type in 99 red in the search textbox and accept the notice that there are several instances of 99 red.

    You will see that the items that fill the listbox are not in the order that I would like for them to be in. (I labeled the columns above the listbox in the order that I would like to see them in)

    BTW, I'm using an inventory searchable file that was posted yesterday by someone where royUK was helping them.

    I think I have it figured out except for this.
    Attached Files Attached Files
    Last edited by jwright650; 02-09-2011 at 02:34 PM. Reason: Listbox cols start with zero not 1, solved
    Life is like a roll of toilet paper. The closer it gets to the end, the faster it goes.
    John Wright

  2. #2
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: Listbox with multi-columns what determines the order of the columns?

    This populates the ListBox
    Please Login or Register  to view this content.
    Your code is actually filtering Column B, the initial search is on D
    Last edited by royUK; 02-09-2011 at 01:13 PM.
    Hope that helps.

    RoyUK
    --------
    For Excel Tips & Solutions, free examples and tutorials why not check out my web site

    Free DataBaseForm example

  3. #3
    Valued Forum Contributor jwright650's Avatar
    Join Date
    12-10-2010
    Location
    Va, USA
    MS-Off Ver
    Excel 2003, Excel 2010
    Posts
    606

    Re: Listbox with multi-columns what determines the order of the columns?

    Thanks Roy,
    I'll dig in there and look at that some more.

  4. #4
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: Listbox with multi-columns what determines the order of the columns?

    I need to go out but I'll post some amended code when I get back

  5. #5
    Valued Forum Contributor jwright650's Avatar
    Join Date
    12-10-2010
    Location
    Va, USA
    MS-Off Ver
    Excel 2003, Excel 2010
    Posts
    606

    Re: Listbox with multi-columns what determines the order of the columns?

    Thanks Roy,

    I got the Listbox column orientation fixed, but I noticed that I can't get the "delete" button to work. I added a bogus paint to my inventory and tried to use the delete button and can't get it to work correctly.

    search, edit, save all seem to perform as expected....just the delete is acting up.
    Attached Files Attached Files

  6. #6
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: Listbox with multi-columns what determines the order of the columns?

    This sorts the listbox - your ColumnWidths were wrong, There seemed to be 10 entries for the 89 Column ListBox

    The delete button is searching on the wrong column. When you click the listbox the textboxes do not populate correctly, you need to adjust them to match the columns in the listbox
    Attached Files Attached Files

  7. #7
    Valued Forum Contributor jwright650's Avatar
    Join Date
    12-10-2010
    Location
    Va, USA
    MS-Off Ver
    Excel 2003, Excel 2010
    Posts
    606

    Re: Listbox with multi-columns what determines the order of the columns?

    Quote Originally Posted by royUK View Post
    your ColumnWidths were wrong,
    The delete button is searching on the wrong column. When you click the listbox the textboxes do not populate correctly, you need to adjust them to match the columns in the listbox
    Check out post#5 and see if that file is better.(cols fill the listbox in the right order and widths were revised also)

    Still can't get the delete button working though. It deletes out of the Listbox but the row with that info still remains on the inventory worksheet.

+ 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