X   Site Message
(Message will auto close in 2 seconds)

Welcome to UtterAccess! Please ( Login   or   Register )

Custom Search
   Reply to this topicStart new topic
> Raised Amount: Text Box With #name? Error, Access 2016    
post Apr 19 2017, 11:08 PM

Posts: 3
Joined: 13-April 17

I'm an access beginner and I've been converting the charitable contributions ms template. I'm running into an issue with one of the forms. The form had a text box with a calculated expression that read =CCur(Nz(DSum("[Amount]","Donations","[Campaign] = " & Nz([ID],0)),0)) . I didn't think I needed the other expression since the text box is formatted for currency. I followed a tutorial on https://theaccessbuddy.wordpress.com/2013/1...ing-a-criteria/ What I ended up with was =DSum("[Amount]","[Grants]","[Project]='" & [Project] & "'") I'm getting either #Name? or #Error and I have no idea why. The expression is pulling info from the [Grants] table and the forms source is from the [Projects] table. The form has 2 tabs a [Details] tab and a [Grants list subform] tab. Could the second tab be the issue since they are both pulling info from the same table?
Go to the top of the page
post Apr 20 2017, 07:56 AM

UtterAccess VIP
Posts: 9,762
Joined: 11-March 05
From: Maryland

Part of your issue might be the naming conventions you are using. I suggest you check out Fully Qualified Naming

“We're run by the Pentagon, we're run by Madison Avenue, we're run by television, and as long as we accept those things and don't revolt we'll have to go along with the stream to the eventual avalanche"
Go to the top of the page
post Apr 20 2017, 09:07 AM

Posts: 4,370
Joined: 11-November 02

One of the first things to look at, in this kind of thing, is the Where Clause. Is Project defined as Text or as a Number/Autonumber? The syntax

"[Project]='" & [Project] & "'"

is only correct if it is defined as Text. If Project is Numeric it'd be

"[Project]=" & [Project]

Linq ;0)>
This post has been edited by missinglinq: Apr 20 2017, 09:22 AM

Hope this helps!

The problem with making anything foolproof...is that fools are so darn ingenious!

All posts/responses based on Access 2003/2007
Go to the top of the page

Custom Search
RSSSearch   Top   Lo-Fi    18th October 2017 - 12:52 AM