Results 1 to 4 of 4
  1. #1
    Join Date
    Jun 2008

    Unanswered: Problem using combo Box Filtering Customer by Employee

    I have Combo box in a form as a search criteria to pull customer information from the tblCustomers and populate the form. The combo box populates the customer names and works as required. But my problems now is how to filter the combo box to populate only the customer assign to a particular employee. For example, I have a table called tblUsers with userID, UserName and UserType.

    Here is the code I used to populate the combo box with the customer names.
    Private Sub cboSelect_AfterUpdate()
    ' Find the record that matches the control.
    Me.RecordSource = "SELECT * FROM tblCustomer WHERE CustomerID = " & Me.cboSelect
    End Sub

    Based on the information above is there any way to twick the code to accomplish to do this. Please note that the main form is bound to tblCustomers

  2. #2
    Join Date
    Jan 2007
    Provided Answers: 12
    How do you identify what employee customer Jeff Smith is assigned to?
    Home | Blog

  3. #3
    Join Date
    Jun 2008

    How do you identify what employee customer Jeff Smith is assigned to?

    Take for example employee John is mapped to Customer Coast Group who purchases shoes and Frank is mapped to Customer ACD USA who purchases cloths. This is mapped against table called cutomer table with their product line. What I want is when John logs to the data base he can only see COAST GROUP information and not ACD USA information.


  4. #4
    Join Date
    Nov 2007
    Adelaide, South Australia
    The answer is to just use criteria in a query.

    Provide some table structure and you will get better help.
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!

    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts