More Order Form Help

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I'm sorry to post again, but i've noticed that sometimes second questions
don't get answered....

I've done the suggested "where" on my productid combo box on my subform.
Step two is giving me problems. It was suggested to requery the productid
combo box (on the subform) in the after event on the supplier box on the main
form. when i try to do this, i get an error message saying that there is no
field named productid in the current record. i'm obviously not referencing
this correctly.

If you need more info, please let me know. Thanks for your help.
 
The requery should look like this:

me.sfrmOrderDetails.form.productid

Replace sfrOrderDetails with the name of the subform control on the main
form and change (if necessary) "productid" to the name of your productid
combo. Note that 'sfrmOrderDetails' must be the name of the subform control
on the main form. This is not necessarily the same as the name of the form
object that is referenced in the ControlSource of the subform control. To be
sure, open the main form and click once on the subform then check the name
property under the Other tab. Whatever you find there is what belongs in
place of "sfrmOrderDetails".
 
Arrrg! I think i need to start from the beginning, because i just am not
getting it.

So:

Main form is called Orders. On it is the SupplierID combo box.
Sub form is called Orders Subform. On it is the ProductID combo box.

Can you write out for me what i need to do on each combo box to make it so
the products displayed in the drop down list are only sold by the supplier
chosen in the supplier box on the main form? Let's assume i know nothing
(which i'm starting to think) and include all the steps.

Thank you so much!

Sandra Daigle said:
The requery should look like this:

me.sfrmOrderDetails.form.productid

Replace sfrOrderDetails with the name of the subform control on the main
form and change (if necessary) "productid" to the name of your productid
combo. Note that 'sfrmOrderDetails' must be the name of the subform control
on the main form. This is not necessarily the same as the name of the form
object that is referenced in the ControlSource of the subform control. To be
sure, open the main form and click once on the subform then check the name
property under the Other tab. Whatever you find there is what belongs in
place of "sfrmOrderDetails".



--
Sandra Daigle [Microsoft Access MVP]
Please post all replies to the newsgroup.

I'm sorry to post again, but i've noticed that sometimes second
questions don't get answered....

I've done the suggested "where" on my productid combo box on my
subform. Step two is giving me problems. It was suggested to requery
the productid combo box (on the subform) in the after event on the
supplier box on the main form. when i try to do this, i get an error
message saying that there is no field named productid in the current
record. i'm obviously not referencing this correctly.

If you need more info, please let me know. Thanks for your help.
 
In the AfterUpdate event of SupplierID put the following statement:

me.[Orders Subform].requery

That's it.

--
Sandra Daigle [Microsoft Access MVP]
Please post all replies to the newsgroup.

Arrrg! I think i need to start from the beginning, because i just am
not getting it.

So:

Main form is called Orders. On it is the SupplierID combo box.
Sub form is called Orders Subform. On it is the ProductID combo box.

Can you write out for me what i need to do on each combo box to make
it so the products displayed in the drop down list are only sold by
the supplier chosen in the supplier box on the main form? Let's
assume i know nothing (which i'm starting to think) and include all
the steps.

Thank you so much!

Sandra Daigle said:
The requery should look like this:

me.sfrmOrderDetails.form.productid

Replace sfrOrderDetails with the name of the subform control on the
main form and change (if necessary) "productid" to the name of your
productid combo. Note that 'sfrmOrderDetails' must be the name of
the subform control on the main form. This is not necessarily the
same as the name of the form object that is referenced in the
ControlSource of the subform control. To be sure, open the main form
and click once on the subform then check the name property under the
Other tab. Whatever you find there is what belongs in place of
"sfrmOrderDetails".



--
Sandra Daigle [Microsoft Access MVP]
Please post all replies to the newsgroup.

I'm sorry to post again, but i've noticed that sometimes second
questions don't get answered....

I've done the suggested "where" on my productid combo box on my
subform. Step two is giving me problems. It was suggested to requery
the productid combo box (on the subform) in the after event on the
supplier box on the main form. when i try to do this, i get an
error message saying that there is no field named productid in the
current record. i'm obviously not referencing this correctly.

If you need more info, please let me know. Thanks for your help.
 
Back
Top