Results 1 to 5 of 5
  1. #1
    5 Star Lounger bfxtrfcmgr's Avatar
    Join Date
    Aug 2002
    Location
    Fresno, California, USA
    Posts
    995
    Thanks
    12
    Thanked 0 Times in 0 Posts

    Criteria Expression (2003)

    In the criteria expression for the combo box
    Bryan,
    Not the smartest critter on the glacier. . .
    . . .but I'm persistent (does that count?)

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Criteria Expression (2003)

    Try
    <code>
    Like "*" & [Forms]![frmOrderDetail]![txtEquipmentType] & "*"</code>

  3. #3
    5 Star Lounger bfxtrfcmgr's Avatar
    Join Date
    Aug 2002
    Location
    Fresno, California, USA
    Posts
    995
    Thanks
    12
    Thanked 0 Times in 0 Posts

    Re: Criteria Expression (2003)

    Hans

    I could have sworn I tried that too, but when I did it this time it worked!
    Except when I change to another record. Maybe that's what happened before.
    I have to requery the record to get it to update the drop down; changing from one record to another doesn't do it. I'm not clear on why that is the case; I thought changing records actually was a requery of the record?
    Bryan,
    Not the smartest critter on the glacier. . .
    . . .but I'm persistent (does that count?)

  4. #4
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Criteria Expression (2003)

    Moving to a different record does update the value displayed in controls (the control source), but it doesn't update the list part of a list box or combo box (the row source). To ensure the row source is updated, put some code in the On Current event of the form:

    Private Sub Form_Current()
    Me.[NameOfComboBox].Requery
    End Sub

    Insert as many requery lines as necessary. You only need them for list boxes and combo boxes whose row source depends on another control on the form, not for list boxes and combo boxes with a static row source.

  5. #5
    5 Star Lounger bfxtrfcmgr's Avatar
    Join Date
    Aug 2002
    Location
    Fresno, California, USA
    Posts
    995
    Thanks
    12
    Thanked 0 Times in 0 Posts

    Re: Criteria Expression (2003)

    Hans

    I see (said the blind man), that's good to know. I think I'll save this thread!
    Thanks for your help and tutelage.
    Bryan,
    Not the smartest critter on the glacier. . .
    . . .but I'm persistent (does that count?)

Posting Permissions

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