DLookup in the query built in the report

T

tanhus

Im trying to figure how to do a dlookup in the query i have built in a
report. Im not too sure of the query name and how to access it.
This is what i have

=DLookUp("[SumOfamount]","*****","[coa_code]= '4500-Face'")

Dont know what to put in for the stars.
Thanks to those who can help
 
F

fredg

Im trying to figure how to do a dlookup in the query i have built in a
report. Im not too sure of the query name and how to access it.
This is what i have

=DLookUp("[SumOfamount]","*****","[coa_code]= '4500-Face'")

Dont know what to put in for the stars.
Thanks to those who can help

Just put in the name of the query.

=DLookUp("[SumOfamount]","QueryName","[coa_code]= '4500-Face'")
 
D

Duane Hookom

Or, if the query is the same as the report's record source, you can use:
=DLookUp("[SumOfamount]",[RecordSource],"[coa_code]= '4500-Face'")


--
Duane Hookom
Microsoft Access MVP


fredg said:
Im trying to figure how to do a dlookup in the query i have built in a
report. Im not too sure of the query name and how to access it.
This is what i have

=DLookUp("[SumOfamount]","*****","[coa_code]= '4500-Face'")

Dont know what to put in for the stars.
Thanks to those who can help

Just put in the name of the query.

=DLookUp("[SumOfamount]","QueryName","[coa_code]= '4500-Face'")
 
T

tanhus

I don't know why but that still gives me an error.

Duane Hookom said:
Or, if the query is the same as the report's record source, you can use:
=DLookUp("[SumOfamount]",[RecordSource],"[coa_code]= '4500-Face'")


--
Duane Hookom
Microsoft Access MVP


fredg said:
Im trying to figure how to do a dlookup in the query i have built in a
report. Im not too sure of the query name and how to access it.
This is what i have

=DLookUp("[SumOfamount]","*****","[coa_code]= '4500-Face'")

Dont know what to put in for the stars.
Thanks to those who can help

Just put in the name of the query.

=DLookUp("[SumOfamount]","QueryName","[coa_code]= '4500-Face'")
 
D

Duane Hookom

You stated you were attempting to do this in the query? Is that correct or is
this the control source of a text box? Please tell us about your report,
record source, and what you hope to accomplish.

--
Duane Hookom
Microsoft Access MVP


tanhus said:
I don't know why but that still gives me an error.

Duane Hookom said:
Or, if the query is the same as the report's record source, you can use:
=DLookUp("[SumOfamount]",[RecordSource],"[coa_code]= '4500-Face'")


--
Duane Hookom
Microsoft Access MVP


fredg said:
On Mon, 5 Feb 2007 13:24:01 -0800, tanhus wrote:

Im trying to figure how to do a dlookup in the query i have built in a
report. Im not too sure of the query name and how to access it.
This is what i have

=DLookUp("[SumOfamount]","*****","[coa_code]= '4500-Face'")

Dont know what to put in for the stars.
Thanks to those who can help

Just put in the name of the query.

=DLookUp("[SumOfamount]","QueryName","[coa_code]= '4500-Face'")
 
T

tanhus

I have built a report. Within the record source of the report i have built a
query. I want to insert a dlookup within a text box (control source) to look
up certain values in this record source query.

Duane Hookom said:
You stated you were attempting to do this in the query? Is that correct or is
this the control source of a text box? Please tell us about your report,
record source, and what you hope to accomplish.

--
Duane Hookom
Microsoft Access MVP


tanhus said:
I don't know why but that still gives me an error.

Duane Hookom said:
Or, if the query is the same as the report's record source, you can use:
=DLookUp("[SumOfamount]",[RecordSource],"[coa_code]= '4500-Face'")


--
Duane Hookom
Microsoft Access MVP


:

On Mon, 5 Feb 2007 13:24:01 -0800, tanhus wrote:

Im trying to figure how to do a dlookup in the query i have built in a
report. Im not too sure of the query name and how to access it.
This is what i have

=DLookUp("[SumOfamount]","*****","[coa_code]= '4500-Face'")

Dont know what to put in for the stars.
Thanks to those who can help

Just put in the name of the query.

=DLookUp("[SumOfamount]","QueryName","[coa_code]= '4500-Face'")
 
D

Duane Hookom

What is the error? What is the exact expression you entered into the control
source? Please explain each argument in the expression so we know where it
comes from and its data type.

--
Duane Hookom
Microsoft Access MVP


tanhus said:
I have built a report. Within the record source of the report i have built a
query. I want to insert a dlookup within a text box (control source) to look
up certain values in this record source query.

Duane Hookom said:
You stated you were attempting to do this in the query? Is that correct or is
this the control source of a text box? Please tell us about your report,
record source, and what you hope to accomplish.

--
Duane Hookom
Microsoft Access MVP


tanhus said:
I don't know why but that still gives me an error.

:

Or, if the query is the same as the report's record source, you can use:
=DLookUp("[SumOfamount]",[RecordSource],"[coa_code]= '4500-Face'")


--
Duane Hookom
Microsoft Access MVP


:

On Mon, 5 Feb 2007 13:24:01 -0800, tanhus wrote:

Im trying to figure how to do a dlookup in the query i have built in a
report. Im not too sure of the query name and how to access it.
This is what i have

=DLookUp("[SumOfamount]","*****","[coa_code]= '4500-Face'")

Dont know what to put in for the stars.
Thanks to those who can help

Just put in the name of the query.

=DLookUp("[SumOfamount]","QueryName","[coa_code]= '4500-Face'")
 

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