How to fix a #Name? Error in Access Report

legalhustler

Well-known Member
Joined
Jun 5, 2014
Messages
1,139
Office Version
  1. 365
  2. 2016
Platform
  1. Windows
Hi All,

I have a report with an unbound textbox field. I go to this fied's control source and use the expression builder to drill down to the query and it's specific field/column (i.e say it has a value of 100) which I want the report to retrieve and display, but it shows a #Name? error. The expression builder automatically gives the correct name of the query and field/column name, so there is no issue with the naming convention.

How can I fix this error so that my textbox in my report returns the value of a specific field in my query?

Below is the expression builder formula. The first bracket syntax is my Query name, the second bracket syntax is the field I want to retrieve: =

Code:
=[Q3 Sum Contracts Less than $1 Million]![SumOfCountOfContract_Action]


Thanks!
 

Excel Facts

Select a hidden cell
Somehide hide payroll data in column G? Press F5. Type G1. Enter. Look in formula bar while you arrow down through G.

ranman256

Well-known Member
Joined
Jun 17, 2014
Messages
2,030
The text box should be bound to the ROWSOURCE. (the field in the forms attached query)
This comes from the form being bound to RECORDSOURCE.


If you have unbound fld..you need to use =DLOOKUP([field],query,"where statement")
you cant just attach a query to an unbound field.
 

legalhustler

Well-known Member
Joined
Jun 5, 2014
Messages
1,139
Office Version
  1. 365
  2. 2016
Platform
  1. Windows
The text box should be bound to the ROWSOURCE. (the field in the forms attached query)
This comes from the form being bound to RECORDSOURCE.


If you have unbound fld..you need to use =DLOOKUP([field],query,"where statement")
you cant just attach a query to an unbound field.

Yeah, I figured DLookup would work also, but for the report I needed to generate had over over 40 queries so I created a Union query and was able to extract the fields to my report from that without any issues.

Thanks.
 

Forum statistics

Threads
1,148,249
Messages
5,745,619
Members
423,963
Latest member
Rayds

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top