Results 1 to 4 of 4
  1. #1
    GregShah is offline Advanced Beginner
    Windows 7 32bit Access 2007
    Join Date
    Feb 2012
    Location
    Canton, Ohio
    Posts
    60

    Selecting between two combo box for same record

    I have a database to track materials going to a subcontractor and also to the end customer. I use two separate forms to track this data with the only difference being the combo box I use to restrict the name of the pieces shipping. I have a form that uses one combo box of items that have not yet shipped to the subcontractor. The other form is exactly the same except the combo box has all of the parts that have not shipped to the customer listed. I even keep this data in the same table.

    Is there a fairly simply method that I can employ that, based on the shipment type, "subcontractor" or "customer", the proper combo box can be selected?



    Thanks for any help,

    Greg Shah

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,930
    The comboboxes are bound to the same field?

    I would use one form and have code that sets the combobox RowSource.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    GregShah is offline Advanced Beginner
    Windows 7 32bit Access 2007
    Join Date
    Feb 2012
    Location
    Canton, Ohio
    Posts
    60
    Currently, I use two queries to track the quantity and name of the parts that need to go to the sub and then to shipping. As long as the quantity is greater than zero, the name of the part appears on the combo list. So the two forms are basically identical except I select the shipment type, sub or shipping, and use the proper query as the combo box list.

    I am not familiar with writing a code to set the RowSource but I am willing to try if its not too far beyond my talents.

    Can I conditionally review the shipment type and then select the corresponding combo box?

    Thanks for your help,

    Greg

  4. #4
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,930
    Options using 1 form:

    1. code in Shipment Type combobox AfterUpdate event sets RowSource property of Parts combobox

    2. code in Shipment Type combobox AfterUpdate event sets 2 Parts comboboxes as visible and not visible

    I prefer option 1.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Combo Box Not selecting value
    By data808 in forum Forms
    Replies: 3
    Last Post: 02-06-2014, 03:06 AM
  2. Replies: 1
    Last Post: 07-12-2012, 08:39 AM
  3. Using a combo box for selecting a form
    By tsn.s in forum Access
    Replies: 5
    Last Post: 11-01-2011, 07:29 AM
  4. Replies: 9
    Last Post: 09-16-2011, 03:52 PM
  5. Selecting Items in a combo box
    By Ferdi in forum Programming
    Replies: 6
    Last Post: 03-15-2011, 09:12 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums