+ Reply to Thread
Results 1 to 9 of 9

Names subtracting after they have already been selected in another combobox.

  1. #1
    Registered User
    Join Date
    07-14-2014
    Location
    glasgow
    MS-Off Ver
    MS 365
    Posts
    39

    Names subtracting after they have already been selected in another combobox.

    Hi there,

    I have a user form that has 28 CoboBoxes, "NameBox1, NameBox2, etc" and there all linked to the same list of names.

    What I would like them to do is when I select a name in each NameBox it will not appear in the other boxes for selection.


    Is this possible???

    Thanks..

  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: Names subtracting after they have already been selected in another combobox.

    Hi,

    Yes indeed. There are no doubt several ways. Off the top of my head the approach I'd probably use is to have a second list of names that is covered by a dynamic range name.

    At the start of your process then copy the main list of names to the column containing the dynamic range name, and use this dynamic range name as the RowSource property for the comboxes. Then each time you select a name in the combobox, use a Find instruction to find that name in the dynamic range and delete that cell moving all the other names upwards.
    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 Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258

    Re: Names subtracting after they have already been selected in another combobox.

    Hello Sean Gillan,

    There are other ways to accomplish what you want. To find out which method will work best, you should post a copy of your workbook.

    How To Post Your Workbook
    1. At the bottom right of the Reply window, Click the button Go Advanced
    2. At the top of the Your Message Window, in the first row of icons, Click the Paperclip icon.
    3. Click the Add Files button at the top right in the dialog box. This displays the File Manager dialog.
    4. Click the Select Files button at the bottom middle of the dialog.
    5. In the new window Find the file you want to upload, select it, and Click Open.
    6. You will now be back in the File Manager dialog. Click the bottom Middle button Upload File.
    7. Wait until the file has completely uploaded before you exit the File Manager dialog.
    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!)

  4. #4
    Registered User
    Join Date
    07-14-2014
    Location
    glasgow
    MS-Off Ver
    MS 365
    Posts
    39

    Re: Names subtracting after they have already been selected in another combobox.

    Here is a copy of my file
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    07-14-2014
    Location
    glasgow
    MS-Off Ver
    MS 365
    Posts
    39

    Re: Names subtracting after they have already been selected in another combobox.

    Richard Buttrey

    Im New at this, i like your idea about the "dynamic range name" but im unsure of what that is. also the "Find instruction" to find that name in the dynamic range and delete that cell moving all the other names upwards.


    Could you explain futher please.

  6. #6
    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: Names subtracting after they have already been selected in another combobox.

    Hi,

    Why is it necessary to have 28 combo boxes for people to sign in?

    Surely four boxes is sufficient since you can only handle one name at a time? After that name has been updated to the system then use the same 4 boxes again (with the names showing one fewer as I mentioned).

  7. #7
    Registered User
    Join Date
    07-14-2014
    Location
    glasgow
    MS-Off Ver
    MS 365
    Posts
    39

    Re: Names subtracting after they have already been selected in another combobox.

    I need the 28 boxes one for each space in the signing in sheet.

    I may need to shuffle people around as im filling the sheet out and i wouldnt like to have to start over again.

  8. #8
    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: Names subtracting after they have already been selected in another combobox.

    Hi,

    I still don't see why you NEED 28 sets of comboboxes. Your code is unnecessarily complicated having to handle all 28. At the moment it seems the only thing the different boxes are doing is positioning the sign in details at a particular position on the sign in sheet. Why not just add each sign in to the next available space on the sign in table and use a check cell to tell when all 28 are filled and reject any more additions.

    If you need to correct an entry just use the same 4 combo boxes but have a 'correction' button which populates the combo boxes with the values for the name selected and either deletes that line moving all others up or edits the 4 entries on the table.

    Just because you have spent a lot of time getting to where you are, don't be too proud to accept that there is still a better way. Believe me I've been there too many times and got so many T shirts I could open a stall on the local market. It seems to me that this is typical of a development process. Two steps back, reviewing and coming up with a neater way forward seems to be common. And if there isn't already a named 'law' for this phenomenon then it's about time there was.

  9. #9
    Registered User
    Join Date
    07-14-2014
    Location
    glasgow
    MS-Off Ver
    MS 365
    Posts
    39

    Re: Names subtracting after they have already been selected in another combobox.

    Hi I do understand what youre saying ive been back and forward with alot of my projects.

    Maybe a poor choice of words on my behalf, i dont NEED 28 boxes but i do feel that the 28 boxes is better and easier to work with on this project, especaly from a users point of veiw.

    I wold Like 28 boxes.

    Could this be done???

+ 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] selected combobox will automatic update in the list to another combobox
    By aimjhun in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 01-20-2014, 07:22 AM
  2. Replies: 3
    Last Post: 04-02-2013, 06:02 PM
  3. I need a ComboBox to return another Combobox if a specific answer is selected
    By concatch in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 10-22-2012, 03:43 AM
  4. 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
  5. get all sheet names in comboBox of activeworkbook and export when selected
    By ilyaskazi in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 06-14-2005, 09:49 AM

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