Results 1 to 6 of 6
  1. #1
    aaron1riley is offline Novice
    Windows 10 Access 2016
    Join Date
    Feb 2021
    Posts
    12

    Please help with Correct query criteria


    Hi,

    hoping someone can please help me with the filtering (navigation subform) of a split from im using. All controls i have to filter the form are working except for my final one which has an added control in form of a checkbox.

    Using a Navigation sub form i would like to select a checkbox which when true only returns records which are not Null from the "Countremeasure" field (from the back end table ) and also only returns records for "Done" (yes/no field) if "No"
    Then if checkbox isnt selected it returns everything.


    Sorry for lack of info that you may need to help as i am a complete novice. Hoping for query criteria statement as im not into coding.

    Thanks and appreciate your time


    Aaron
    Attached Thumbnails Attached Thumbnails PXL_20220725_105122354.jpg  

  2. #2
    Bob Fitz's Avatar
    Bob Fitz is offline Access Developer
    Windows 10 Access 2016
    Join Date
    May 2011
    Location
    Essex UK
    Posts
    3,540
    Can you post a copy of the db
    If this helped, please click the star at the bottom left of this posting and add to my reputation . Many thanks.
    Bob Fitzpatrick

  3. #3
    aaron1riley is offline Novice
    Windows 10 Access 2016
    Join Date
    Feb 2021
    Posts
    12
    Hi Bob, id like to but cant due to company policy. is there any other generic info i can give that can aid you?

  4. #4
    Micron is online now Virtually Inert Person
    Windows 10 Access 2016
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,793
    Hard to see the criteria but it looks like True is wrapped in dbl quotes ("True") which is probably being interpreted as a text value, not as T or F. The "No " & in Done field looks wrong as well in that it's text again, and I can't imagine a checkbox field (Done) containing a string like No. Try removing the concatenation from each field as a start. Also, this seems contradictory: checkbox which when true only returns records which are not Null

    yet you specify Null & in the Countermeasure field. If the criteria is True, then checking for anything else doesn't make sense.
    The more we hear silence, the more we begin to think about our value in this universe.
    Paraphrase of Professor Brian Cox.

  5. #5
    aaron1riley is offline Novice
    Windows 10 Access 2016
    Join Date
    Feb 2021
    Posts
    12
    Quote Originally Posted by Micron View Post
    Hard to see the criteria but it looks like True is wrapped in dbl quotes ("True") which is probably being interpreted as a text value, not as T or F. The "No " & in Done field looks wrong as well in that it's text again, and I can't imagine a checkbox field (Done) containing a string like No. Try removing the concatenation from each field as a start. Also, this seems contradictory: checkbox which when true only returns records which are not Null

    yet you specify Null & in the Countermeasure field. If the criteria is True, then checking for anything else doesn't make sense.


    Thanks for your help, your suggestions aided my solution.

  6. #6
    Micron is online now Virtually Inert Person
    Windows 10 Access 2016
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,793
    Glad I was able to assist somehow.
    The more we hear silence, the more we begin to think about our value in this universe.
    Paraphrase of Professor Brian Cox.

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

Similar Threads

  1. Replies: 2
    Last Post: 05-13-2016, 07:31 PM
  2. Can't seem to get the criteria expression correct
    By GraeagleBill in forum Queries
    Replies: 2
    Last Post: 10-25-2015, 05:16 PM
  3. Replies: 5
    Last Post: 09-12-2014, 06:41 AM
  4. Replies: 9
    Last Post: 06-26-2011, 09:14 PM
  5. Replies: 6
    Last Post: 01-07-2011, 12:50 PM

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