Results 1 to 4 of 4
  1. #1
    Join Date
    Jan 2003
    Posts
    3

    Unanswered: Stuck with combo boxes

    Im new with access and am having troble with combo boxes.

    Im making a new form with 2 combo boxes.

    1) Username
    2) Department

    I want to connect them, so that when a department is selected the list in the combobox allows only the username thats in the department.

    If someone can help me with this problem it would be greatly appreciated.

    Thanx

  2. #2
    Join Date
    Nov 2002
    Posts
    150

    Re: Stuck with combo boxes

    Need to write some code in the OnClick event of the Department combo. Try:

    <username conbo>.RowSource = "SELECT <fields> FROM <table> WHERE <key> = " & Me.<department combo>

    if the <key> in a text field, use

    Username.RowSource = "SELECT <fields> FROM <table> WHERE <key> = '" & Me.<department combo> & "'"

    Everything in <> needs to be filled in with the specific names from your app.

  3. #3
    Join Date
    Jan 2003
    Posts
    3

    Re: Stuck with combo boxes

    Im still having troubles..

    It's now asking for a Parameter value, when i click on the username combo box.

    Im not sure what that means.

    Thanx

  4. #4
    Join Date
    Jan 2003
    Posts
    3

    Re: Stuck with combo boxes

    actually got to work...

    Thanx alot

Posting Permissions

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