I have a database for animals. In the main table I have fields for the sys_id, animal_name, and animal_regno. Further down in the table I have fields for the sireid, sire-name and sire-reg-no. I have performed a query to pull selected fields out of this primary table and have saved it. One thing that I have noticed is when I go to the relationships window and create the relationship between the main table and the qry table by the sys_id field that it does not display a one-to-one or a one-to-many relationship. Should it? If so what would cause it not to?
I have created a combo box on my form and used the qry for the data that I want. This part works fine and it does display the data like I need.
In the form I rename the Combo88 to cbo-sire-id and then the other fields associated with this information I have put the words txt in front of them. Then I have the combo box highlighted and select "Event" and then select "On Change" and this is what I have put in the coding:
Private Sub cbo_sire_id_Change()
Me.txt_sire_name.Value = Me.cbo_sire_id.Column(1)
End Sub
But whenever I try to use the combo box, the auto populate does not work.
Thinking that it could be because of the hyphens and underlines, I have even gone back and renamed the fields with letters only such as txtsirename, etc, but this still did not make any difference.
Also thinking that it could be a possibility that the number of fields in the form could be the problem, I have created a form with just the few fields involved. That didn't work either, as the auto populate still failed.
Thanks and hopefully someone can answer with a solution.