Posts by Wozzie

    I'm having problems with your workbook. I think the issue with your code is that you have put the comboboxes in Frames.

    Does the userform and controls need to be so big?

    Roy, I did wonder if the form would be too big for my son's MacBook! But my problem is that he (the user) will need to select more than 15 items (from the same range) in some of the cost categories and I thought that using the frames was a neat way of putting 30 choices on the one form. The smaller categories will work fine with a single userform and the 'Nodupe' coding that you kindly provided. But it appears that I will not be able to use any form of dupe control across say 25 comboboxes unless I split a cost category range into two, and then have one userform for each half. In which case I will need many userforms by the time I receive all of his cost categories.


    You can use the function on any of the UserForms

    Yes Roy, the function is working on both UF_PlasterP1 and P2 UserForms, and my other UF's are picking it up ok too. My problem is that I'm using P2 as an extension of P1 to add more materials using the same range as P1. But ValueSelected function starts afresh on P2 , thus P2 user selections can be duplicated from P1. So my question is can the "already selected" message show if a P2 selection was selected on P1 (without having to rebuild using multipage controls)?

    I hope this better explains my problem.



    Roy, I've amended my code to move the ValueSelected function to a public module and it's working on both P1 and P2. But I may have my wires crossed! Does this just tidy things up in terms of coding other forms, or can the ValueSelected carry over from P1 to P2? I'm still using the add-on form at this stage rather than Multipage.



    Thanks Roy, I've applied your code across user forms PlasterCodesP1 and P2, and it works a treat. The P2 form is a continuation from P1 for instances when more than 15 of the PL code materials would be required. Is there any way that the P1 Function etc can carry over to P2 rather than it starting afresh in P2?

    Not exactly sure what you're asking...

    If you mean removing duplicate items in your combo boxes, try this...

    Thanks and I apologise if my post led to some confusion. To clarify, I don't have duplications in my range, It is duplicate user selections that i'm trying to guard against by having combobox1 user selection beremoved from combobox2 list; combobox 1 & combobox2 user selections being removed from combobox 3 list etc.

    Hi Everyone, I'm fairly new to Excel VBA but I'm having a go at building a pricing model with vba user forms for selecting job materials etc. My cost_cat forms have 15 comboboxes for choosing items from a specific range. This is working ok but I want to avoid user duplication of items. Is it possible for combobox selections to be removed or hidden from the following comboboxes? My range is 3 columns but only column(1) (item description) populates the combobox list, whilst column(2) (cost code) and column(3) (pack type) populate an adjacent textbox and labelbox via the change routines for each combobox . Here is my no doubt, very basic code. Any help will be very much appreciated.