How to limit list of a field based on another field in the same ta

C

Cam

Hello,

I am trying to create a form where there are fields in the table which
include Order#, Oper#, Mach#, etc.. I also have another appended table with
simular info except numbers of Oper# depended on Order# (these changes daily
depending on what operation the orders are at).

What I would like to acheive is when the user enter the Order# field, then
the Oper# field list is limited (filtered) based on the Order# selected?
In the Row Source on the Oper# field query, I put the criteria
"[tbl]![DataEntry]!Order#" under Order# criteria, but each time I select the
Oper# field, it pop up a message using to input the Order#. I would like it
to somehow tie to the Order# field so user wouldn't have to re-enter the
Order# in the pop up.

Thanks
 
J

John W. Vinson

Hello,

I am trying to create a form where there are fields in the table which
include Order#, Oper#, Mach#, etc.. I also have another appended table with
simular info except numbers of Oper# depended on Order# (these changes daily
depending on what operation the orders are at).

What I would like to acheive is when the user enter the Order# field, then
the Oper# field list is limited (filtered) based on the Order# selected?
In the Row Source on the Oper# field query, I put the criteria
"[tbl]![DataEntry]!Order#" under Order# criteria, but each time I select the
Oper# field, it pop up a message using to input the Order#. I would like it
to somehow tie to the Order# field so user wouldn't have to re-enter the
Order# in the pop up.

Thanks

You cannot do this in a Table, but then you should never be using table
datasheets for routine data interaction anyway. It's easy to create a
conditional combo box on a Form, however; use a combo with a criterion

=Forms![YourFormName]![Order#]

and requery it in the afterupdate event of the order combo.

Note that the # character is a Date delimiter, and should not be used in
fieldnames; if you do so, you must always enclose the fieldname in square
brackets.
 
C

Cam

Hi John,

Sorry about the multiple posts, not sure where to post it first.
Anyway, from what I understand is:
1) Change the Oper# to an unbound combo box.
2) Put "=Forms!frmOutputEntry!ProdOrd" under Control Source.

Thank

John W. Vinson said:
Hello,

I am trying to create a form where there are fields in the table which
include Order#, Oper#, Mach#, etc.. I also have another appended table with
simular info except numbers of Oper# depended on Order# (these changes daily
depending on what operation the orders are at).

What I would like to acheive is when the user enter the Order# field, then
the Oper# field list is limited (filtered) based on the Order# selected?
In the Row Source on the Oper# field query, I put the criteria
"[tbl]![DataEntry]!Order#" under Order# criteria, but each time I select the
Oper# field, it pop up a message using to input the Order#. I would like it
to somehow tie to the Order# field so user wouldn't have to re-enter the
Order# in the pop up.

Thanks

You cannot do this in a Table, but then you should never be using table
datasheets for routine data interaction anyway. It's easy to create a
conditional combo box on a Form, however; use a combo with a criterion

=Forms![YourFormName]![Order#]

and requery it in the afterupdate event of the order combo.

Note that the # character is a Date delimiter, and should not be used in
fieldnames; if you do so, you must always enclose the fieldname in square
brackets.
 
J

John W. Vinson

Hi John,

Sorry about the multiple posts, not sure where to post it first.
Anyway, from what I understand is:
1) Change the Oper# to an unbound combo box.
2) Put "=Forms!frmOutputEntry!ProdOrd" under Control Source.


No, I did not say that, nor do I understand what you expect this to accomplish
(other than to display the same data as is already in the combo box a second
time).
 
C

Chegu Tom

I think he meant for you to have a BOUND combo box and set the combobox
ROWSOURCE to a query with the criteria of that query being
"=Forms!frmOutputEntry!ProdOrd"


Cam said:
Hi John,

Sorry about the multiple posts, not sure where to post it first.
Anyway, from what I understand is:
1) Change the Oper# to an unbound combo box.
2) Put "=Forms!frmOutputEntry!ProdOrd" under Control Source.

Thank

John W. Vinson said:
Hello,

I am trying to create a form where there are fields in the table which
include Order#, Oper#, Mach#, etc.. I also have another appended table
with
simular info except numbers of Oper# depended on Order# (these changes
daily
depending on what operation the orders are at).

What I would like to acheive is when the user enter the Order# field,
then
the Oper# field list is limited (filtered) based on the Order# selected?
In the Row Source on the Oper# field query, I put the criteria
"[tbl]![DataEntry]!Order#" under Order# criteria, but each time I select
the
Oper# field, it pop up a message using to input the Order#. I would like
it
to somehow tie to the Order# field so user wouldn't have to re-enter the
Order# in the pop up.

Thanks

You cannot do this in a Table, but then you should never be using table
datasheets for routine data interaction anyway. It's easy to create a
conditional combo box on a Form, however; use a combo with a criterion

=Forms![YourFormName]![Order#]

and requery it in the afterupdate event of the order combo.

Note that the # character is a Date delimiter, and should not be used in
fieldnames; if you do so, you must always enclose the fieldname in square
brackets.
 
C

Cam

Hi,

I tried the suggestion, but not working. It gave me an error saying
something like invalid name or similar.

I put "=Forms!frmOutputEntry!ProdOrd" in the Row Source field and Operation
(bound) in the Source Data field of the properties.


Chegu Tom said:
I think he meant for you to have a BOUND combo box and set the combobox
ROWSOURCE to a query with the criteria of that query being
"=Forms!frmOutputEntry!ProdOrd"


Cam said:
Hi John,

Sorry about the multiple posts, not sure where to post it first.
Anyway, from what I understand is:
1) Change the Oper# to an unbound combo box.
2) Put "=Forms!frmOutputEntry!ProdOrd" under Control Source.

Thank

John W. Vinson said:
Hello,

I am trying to create a form where there are fields in the table which
include Order#, Oper#, Mach#, etc.. I also have another appended table
with
simular info except numbers of Oper# depended on Order# (these changes
daily
depending on what operation the orders are at).

What I would like to acheive is when the user enter the Order# field,
then
the Oper# field list is limited (filtered) based on the Order# selected?
In the Row Source on the Oper# field query, I put the criteria
"[tbl]![DataEntry]!Order#" under Order# criteria, but each time I select
the
Oper# field, it pop up a message using to input the Order#. I would like
it
to somehow tie to the Order# field so user wouldn't have to re-enter the
Order# in the pop up.

Thanks

You cannot do this in a Table, but then you should never be using table
datasheets for routine data interaction anyway. It's easy to create a
conditional combo box on a Form, however; use a combo with a criterion

=Forms![YourFormName]![Order#]

and requery it in the afterupdate event of the order combo.

Note that the # character is a Date delimiter, and should not be used in
fieldnames; if you do so, you must always enclose the fieldname in square
brackets.
 
C

Chegu Tom

You didn't read instructions well? Do you know how to create queries? You
need to make one as the ROWSource

You don't put "=Forms!frmOutputEntry!ProdOrd" as the entire rowsource!
You build a Query for the rowsource
the CRITERIA part of the query has a reference to
"=Forms!frmOutputEntry!ProdOrd"




Cam said:
Hi,

I tried the suggestion, but not working. It gave me an error saying
something like invalid name or similar.

I put "=Forms!frmOutputEntry!ProdOrd" in the Row Source field and
Operation
(bound) in the Source Data field of the properties.


Chegu Tom said:
I think he meant for you to have a BOUND combo box and set the combobox
ROWSOURCE to a query with the criteria of that query being
"=Forms!frmOutputEntry!ProdOrd"


Cam said:
Hi John,

Sorry about the multiple posts, not sure where to post it first.
Anyway, from what I understand is:
1) Change the Oper# to an unbound combo box.
2) Put "=Forms!frmOutputEntry!ProdOrd" under Control Source.

Thank

:

On Tue, 18 Aug 2009 09:18:01 -0700, Cam
<[email protected]>
wrote:

Hello,

I am trying to create a form where there are fields in the table
which
include Order#, Oper#, Mach#, etc.. I also have another appended
table
with
simular info except numbers of Oper# depended on Order# (these
changes
daily
depending on what operation the orders are at).

What I would like to acheive is when the user enter the Order# field,
then
the Oper# field list is limited (filtered) based on the Order#
selected?
In the Row Source on the Oper# field query, I put the criteria
"[tbl]![DataEntry]!Order#" under Order# criteria, but each time I
select
the
Oper# field, it pop up a message using to input the Order#. I would
like
it
to somehow tie to the Order# field so user wouldn't have to re-enter
the
Order# in the pop up.

Thanks

You cannot do this in a Table, but then you should never be using
table
datasheets for routine data interaction anyway. It's easy to create a
conditional combo box on a Form, however; use a combo with a criterion

=Forms![YourFormName]![Order#]

and requery it in the afterupdate event of the order combo.

Note that the # character is a Date delimiter, and should not be used
in
fieldnames; if you do so, you must always enclose the fieldname in
square
brackets.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top