Hi,
I'm new to the forum so if I have posted this question in the wrong section then I apologise.
I've just started building a database which contains data for a fish tagging project which allows us to enter data for when a fish was caught and subsequently when it is recaptured. I have a separate subform for both initial capture data and recapture data that link back to a main form (Using master and child links) that includes non-biological fields such as date, location, etc. My capture data subform is called catch_subfrm and links back to a table called catch_tbl. My recapture form and table are similarly named recapture_subfrm and recapture_tbl.
At the moment I enter data in these fields for both forms:
Tag_ID, Species_ID, Sex
In the catch_subform the first two are text boxes with a text format and sex is a combobox.
In my recapture_subform I have Tag_ID set up as a combobox which pulls the tag numbers from the catch_tbl and works fine. However, I would like to auto fill the next 2 columns automatically. I've attempted adding an after_update for the Tag_ID field in recapture_subform using the following code:
[Species_ID] = DLookup("[Species_ID]", "[Catch_tbl]", "[Tag_ID]=" & "[Tag_ID]")
However, it doesn't work and I get no error messages. I've used this code (with different fields) in different forms and tables without problems in the past but this one won't work for some reason. I've tried a few different suggestions for similar problems on other forums but with no success. If anyone could offer any advice I'd be very grateful. I'm hoping it's something simple which I've overlooked.
Cheers,
Jon