Ask Experts Questions for FREE Help !
Ask
    mcleyn's Avatar
    mcleyn Posts: 48, Reputation: 1
    Junior Member
     
    #1

    May 21, 2010, 11:20 AM
    Report Sum totals
    Hi there,

    I have made a report from a query. I want to sum the totals from a totals column. I have had luck summing the totals from my other columnms by putting a text box control source to =sum(Name) of the appropriate textbox. However for this column I use the same expression =sum(Name) however I get "Enter Parameter Value" when I run the report.

    Does it have to do with the fact that my totals column in the report comes from a calculation field done in the query?
    ScottGem's Avatar
    ScottGem Posts: 64,966, Reputation: 6056
    Computer Expert and Renaissance Man
     
    #2

    May 21, 2010, 12:15 PM

    When Access prompts you for a parameter value it is finding a name it can't resolve so it assumes you want to enter it as a parameter. Usually this occurs when you are misspelling the object name. So the first thing to check is the object name.
    mcleyn's Avatar
    mcleyn Posts: 48, Reputation: 1
    Junior Member
     
    #3

    May 21, 2010, 12:19 PM
    Quote Originally Posted by ScottGem View Post
    When Access prompts you for a parameter value it is finding a name it can't resolve so it assumes you want to enter it as a parameter. usually this occurs when you are misspelling the object name. So the first thing to check is the object name.

    I have triple-checked the object name and both are correct.
    What else is do you think the problem may be?
    ScottGem's Avatar
    ScottGem Posts: 64,966, Reputation: 6056
    Computer Expert and Renaissance Man
     
    #4

    May 21, 2010, 01:12 PM

    Are you summing the column name from the query or the control name on the form?
    mcleyn's Avatar
    mcleyn Posts: 48, Reputation: 1
    Junior Member
     
    #5

    May 25, 2010, 07:30 AM
    Quote Originally Posted by ScottGem View Post
    Are you summing the column name from the query or the control name on the form?
    Both names are the same.
    In the query I have made a column called Total Funding Requested which adds funds over four years.
    In the detail part of my form I have a Total Funding Requested text boxes which collect the values from my query. Then in the appropriate footer I put in a textbox and under the control source I use the expression =Sum(TotalFundingRequested) but I get "Enter Parameter Value" for Total Funding Requested.
    Perhaps it is the expression that is wrong?
    ScottGem's Avatar
    ScottGem Posts: 64,966, Reputation: 6056
    Computer Expert and Renaissance Man
     
    #6

    May 25, 2010, 08:12 AM

    First, does the name have spaces in it? Your SUM() doesn't. Also try:
    =Sum([TotalFundingRequested])
    mcleyn's Avatar
    mcleyn Posts: 48, Reputation: 1
    Junior Member
     
    #7

    May 25, 2010, 08:19 AM
    Quote Originally Posted by ScottGem View Post
    First, does the name have spaces in it? Your SUM() doesn't. Also try:
    =Sum([TotalFundingRequested])
    Wow! Thank you so much ScottGem. My query column that I made had spaces in the name which was why it was not working. I did not know such a small thing could make such a big problem. Thank you!
    ScottGem's Avatar
    ScottGem Posts: 64,966, Reputation: 6056
    Computer Expert and Renaissance Man
     
    #8

    May 25, 2010, 09:16 AM
    Quote Originally Posted by mcleyn View Post
    I did not know such a small thing could make such a big problem. Thank you!
    One should NEVER use spaces in object names. This will often come back to haunt you as it has done here. Either use camel notation:

    TotalFundingRequested

    Or underscores:

    Total_Funding_Requested

Not your question? Ask your question View similar questions

 

Question Tools Search this Question
Search this Question:

Advanced Search

Add your answer here.


Check out some similar questions!

Sum result stored in text box in vb data report [ 1 Answers ]

I have two text boxes to sum in detail section of vb data report and I want to sum in 3rd text box like this in detail section : rpttext1 = rpttext2 + rpttext3

Sum two fields in detail section of vb data report [ 1 Answers ]

Dear Sir, I am using VB Data report and I am getting problem in putting formula How can I get result of sum of two fields in detail section of data report like: text1= Field1 + Field2 (Detail Section) Please give me an early response.


View more questions Search