Results 1 to 3 of 3
  1. #1
    4 Star Lounger
    Join Date
    May 2003
    Location
    Manchester, Gtr Manchester, England
    Posts
    552
    Thanks
    0
    Thanked 0 Times in 0 Posts

    queries and criteria (2000)

    I have a query thats takes a date from a range inputted on a user form, how can I have the query run all dates if the user does not select dates in the form?

    Thanks Darren.

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

    Re: queries and criteria (2000)

    Instead of putting the criteria under the date field, do it like this:
    In an empty column of the query grid, enter

    [Forms]![FormName]![StartDate]

    and in the criteria line, enter

    <=[DateField] Or Is Null

    In the next empty column of the query grid, enter

    [Forms]![FormName]![EndDate]

    and in the criteria line, enter

    >=[DateField] Or Is Null

    Substitute the correct names.

  3. #3
    4 Star Lounger
    Join Date
    May 2003
    Location
    Manchester, Gtr Manchester, England
    Posts
    552
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: queries and criteria (2000)

    In debted again.

    Thanks

Posting Permissions

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