Default value on form coming from another table

G

Geraldwho

i would like to have the default value for my Inspector field on my
InspectionForm form come from my CompanyInfo table from a field called
Definsp. Since this table only has 1 record, can i get this value and pass it
on to the form control as a default value?
 
D

Damon Heron

yourformcontrol= nz(dlookup("Definsp", "CompanyInfo"),0)

check out dlookup in help.

Damon
 
J

John W. Vinson

i would like to have the default value for my Inspector field on my
InspectionForm form come from my CompanyInfo table from a field called
Definsp. Since this table only has 1 record, can i get this value and pass it
on to the form control as a default value?

Set the textbox's DefaultValue property to

=DLookUp("Definsp", "CompanyInfo")
 
G

Geraldwho

thanks. i got hung up with the syntax. (again)

Damon Heron said:
yourformcontrol= nz(dlookup("Definsp", "CompanyInfo"),0)

check out dlookup in help.

Damon
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top