Parameter Queries

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • crispydcrisp@googlemail.com

    Parameter Queries

    HELP!!!! I have a form with a combo box to select "Staff ID" and a
    Calendar which puts the selected date into my "Date" field. These two
    fields are the criteria for my parameter query. I then have a form
    which reads from this query. This works fine!!! :)
    the problem is that i want to be able to open this query (form) from
    more than one selection form, so i assumed that in the criteria i
    could just write the name of the "staff id" on form 1 and then put
    "Or" and then "staff id" from form 2...but when i am on the form
    selecting my staff id and date i select ok to run the query (open the
    form) and it then wants both of the selection fields not just one..

    any ideas?

    thanks

  • Harry Skelton

    #2
    Re: Parameter Queries

    On Fri, 18 Apr 2008 06:43:37 -0700, crispydcrisp wrote:
    "staff id" on form 1 and then put "Or" and then "staff id" from form
    2...but when i am on the form selecting my staff id and date i select ok
    to run the query (open the form) and it then wants both of the selection
    fields not just one..
    Since you are basing this on a query, the problem is that both fields are
    not the same name. If you want to use the information of this form as
    part of other forms, you need to include it in the form you are working
    with as a sub form. Otherwise what you do is take the combo box and Copy
    it, then past it into the new form. The effects should be the same.

    But if you want to have more than one entry and then collect data from
    either or, you will have to code it in and not simply have it linked to a
    query. After they enter the data you'll have to build your query, run it
    to see if the data is valid, then display whatever.

    Comment

    Working...