"no****@thankyou.com" <mi*****@yahoo.comwrote in
news:11**********************@j4g2000prf.googlegro ups.com:
Since I haven't gotten any responses, I will try to re-explain
the situation:
I have this cross reference table.
It has the following:
CID cross reference PK
CustomerNumber - the customer's number
RelatedCustomerNumber - the numbers related to that customer
number RelatedID - the Customer PK for the related number (so
that you can find them on the entry form)
So, on the main customer entry form, there is a combo box,
where you can type or scroll and select a customer number.
I now also have a related subform, to show related records.
This button should let you choose a related record to go to.
The customer combo cmbCustNum, has a row source query of the
Customer PK and CustomerNumber. It shows the CustomerNumber,
but is tied to the Customer PK.
I need that combo button to take me to a related record on the
main form. Once I am there, I need to be able to go to any
related record (including back to the one I came from) that
exist on the sub related form for that customer.
Make sense?
No. There is no such control as a combobutton. there are
comboboxes and there are commandbuttons.
I think what you want to do is click on a button in the subform
and have the mainform move to the selected record. Is that
right?
If yes, and the combobox currently correctly lets you choose the
desired record, all you need is for the onclick event of the
subform, set the new value of the combobox.
Parent.cmbCustNum = me.PrimaryKey
is the code to set the new value.
You may also need to trigger the combo box afterUpdateEvent
after setting the new value.
CALL cmbCustNum_afterUpdate
You will need to change the
private sub cmbCustNum_afterUpdate
to
public sub .cmbCustNum_afterUpdate
in the parent form to make it accessible to the subform.
Thank you for any help that you can give.
I Hope I've helped.
--
Bob Quintal
PA is y I've altered my email address.
--
Posted via a free Usenet account from
http://www.teranews.com