Return Query Value to Form Field

  • Thread starter Thread starter NeoFLeX
  • Start date Start date
N

NeoFLeX

Greetings:

I have a select query (Called queryPhones) that returns a single
result, with a single column called queryPhoneNumber. I want to be able
to set the default value of a Form field to the value returned by the
query. I'm using the code:

Forms!testConfirm!testPhone.DefaultValue = """" &
[queryPhones]![queryPhoneNumber] & """"

The query will only ever return one result.

NeoFLeX
neoflex at gmail dot com
 
Try:

Forms!testConfirm!testPhone.DefaultValue =
DFirst("[queryPhoneNumber]","queryPhones")

HTH,
Nikos
 

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

Back
Top