Troubles with control sourrce for a text box

C

CristianTCDM

Hello evrybody,

I am trying to set the control source of an unbound textbox on a form . I
used the following syntax :

=[RPfeedbackPART1]![Med]

The result is only # Name ?.
RPfeedbackPART1 is a Query and Med is one of his fields .

Thanks for any idea
 
J

John W. Vinson

Hello evrybody,

I am trying to set the control source of an unbound textbox on a form . I
used the following syntax :

=[RPfeedbackPART1]![Med]

The result is only # Name ?.
RPfeedbackPART1 is a Query and Med is one of his fields .

Thanks for any idea

You can't refer to queries in this way. What is RPfeedbackPART1? Does it
contain only one record, or do you have some way to determine which record
should be displayed based on the other contents of the form?

If it's a single-record query then you can use

=DLookUp("[Med]", "[RPfeedbackPart1]")

as the recordsource. If not... more info needed!
 
C

CristianTCDM

Yes , it is a single row query .

I tried your sugestion with DLookup function and it works .

Thank you very much !

John W. Vinson said:
Hello evrybody,

I am trying to set the control source of an unbound textbox on a form . I
used the following syntax :

=[RPfeedbackPART1]![Med]

The result is only # Name ?.
RPfeedbackPART1 is a Query and Med is one of his fields .

Thanks for any idea

You can't refer to queries in this way. What is RPfeedbackPART1? Does it
contain only one record, or do you have some way to determine which record
should be displayed based on the other contents of the form?

If it's a single-record query then you can use

=DLookUp("[Med]", "[RPfeedbackPart1]")

as the recordsource. If not... more info needed!
 

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