form populated from 2 tables - not working

magster06

Registered User.
Local time
Today, 14:23
Joined
Sep 22, 2012
Messages
235
Hello All,

I have a form that has several textboxes on it. The form is populated from 2 tables: CellPhoneData and UnitName

The main form is bound to the CellPhoneData table.

2 of the textboxes on the form are to receive their data from the UnitName; these are the ones not populating.

In the control source of the txtUnitName I placed this:

=[UnitName]![Unit Name]

but all I get is #Name? , which I gather it cannot find the data

Any ideas?
 
1. Unless you have the same field in both tables (and then why would you need to have the Unit Name in there if you did, which would indicate you have it set up correctly), you don't need to use the table name. Just use
=[Unit Name]

Others say they have had no problem but I have, if I don't rename my controls on the form to something other than the field it is bound to if there is an expression on the form or report (on report this is quite important). So if you have a control named Unit Name on the form, rename it to something like txtUnitName and then make sure your expression is referring to the field (if auto correct is on it will rename the item in your expression, so you might want to turn that off if first).

Also, make sure that the field is actually selected in the form's record source.
 
So if you have a control named Unit Name on the form, rename it to something like txtUnitName
:)

Also, make sure that the field is actually selected in the form's record source

I already have the first table named as the record source. So, I gather that I am able to add the second table as well?

Would I just use a comma? or semi colon?
 
Ok,

I got it Bob!

I am learning something new everyday with Access.

I was adding textboxes by just dragging them onto the form, but I just found where I can use the "Add Existing Fields" to create auto links.

Thanks again!! (you got me pointed in the right direction)
 

Users who are viewing this thread

Back
Top Bottom