D
Dermot Hayes
I posted a question a few weeks ago regarding validation
rules. I have looked into the answer I got but am still no
further on can anyone help please. I am only a beginner!
My question:- If I create a table with a field called Job
number etc. How do I do I write a vaildation rule so that
when an incorrect job number or rubbish is entered into
the parameter query instead of a valid job number, a
message box is displayed saying "Please Enter a Valid Job
Number"
The answer I recieved is as follows:-
You cannot vaildate the value entered in a queries
parameter prompt.
It is better to create a form that will provide criteria
for the query. The query can use the forms control's
reference as the parameter e.g.
PARAMETERS Forms!frmcriteria!textJobNumber Long:
SELECT....
FROM
WHERE Job Number= Forms! frmcriteria!txtJobNumber
The form has to be open for the query to work.
This methodology has been described many times in this and
other Access news groups. It is also described in the
Access help article Parameter Queries: Create a parameter
Query.
I have read the suggested articles and can't figure out
where I am supposed to enter the above information when I
am creating a form.e.g
PARAMETERS
SELECT....
FROM....
WHERE ETC...
What do I type in the select and From Options above?
Am I trying to do this the correct way? I want to call up
only a Valid Job Number Record,(when someone clicks on
a "NEXT JOB" button on the form I have created), from the
table of records I have created. If an invalid Job
Number / rubbish which is not in the table is is called
up, I would like a prompt
to Say "Please Enter a valid Job Number"
Please Help
Thanks
Dermot
rules. I have looked into the answer I got but am still no
further on can anyone help please. I am only a beginner!
My question:- If I create a table with a field called Job
number etc. How do I do I write a vaildation rule so that
when an incorrect job number or rubbish is entered into
the parameter query instead of a valid job number, a
message box is displayed saying "Please Enter a Valid Job
Number"
The answer I recieved is as follows:-
You cannot vaildate the value entered in a queries
parameter prompt.
It is better to create a form that will provide criteria
for the query. The query can use the forms control's
reference as the parameter e.g.
PARAMETERS Forms!frmcriteria!textJobNumber Long:
SELECT....
FROM
WHERE Job Number= Forms! frmcriteria!txtJobNumber
The form has to be open for the query to work.
This methodology has been described many times in this and
other Access news groups. It is also described in the
Access help article Parameter Queries: Create a parameter
Query.
I have read the suggested articles and can't figure out
where I am supposed to enter the above information when I
am creating a form.e.g
PARAMETERS
SELECT....
FROM....
WHERE ETC...
What do I type in the select and From Options above?
Am I trying to do this the correct way? I want to call up
only a Valid Job Number Record,(when someone clicks on
a "NEXT JOB" button on the form I have created), from the
table of records I have created. If an invalid Job
Number / rubbish which is not in the table is is called
up, I would like a prompt
to Say "Please Enter a valid Job Number"
Please Help
Thanks
Dermot