RE: How do I display averages on a form.

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance

From: rpw (rpw_at_discussions.microsoft.com)
Date: 06/28/04


Date: Mon, 28 Jun 2004 16:51:01 -0700

Hi Steve,

I'm not quite sure why you would want to have the average answer viewable by the user entering answers, but here's a suggestion on how to go about it.

Build a query to get the averages, then build a subform that displays the results of the query, then add the subform to your main form. Note that the average will take into account any Nulls in the data and the query's datasheet view of the averages will probably have several digits behind the decimal point. On the form, format the textbox to display a whole integer.

Hope this helps

-- 
rpw
"Steve Goodrich" wrote:
> How do I display averages on a form.
> 
> I have a database that I am setting up for a customer survey with 600
> records (Access 97)
> 1 table, Field Names are -  Name, Dept, Question 1 Question 2 etc a few
> queries (Question 1 Question 2etc)and 1 form.
> There will be questions for the user to answer using 5 option groups that
> will be set up as follows,  Excellent, Good, Average, Poor and Very Poor.
> Excellent will be set to 5 Good 4 Average 3 Poor 2 and Very Poor 1.
> 
> A query is set up to display all the users that have completed the survey,
> fields -  name, question 1
> 
> What I would like to do is display the average mark for each question on the
> form
> 
> I enter the following in a text box =avg([question1])
> The average is displayed for the Table using all 600 records.( from the
> field name "question 1" on my main table I assume)
> I want to display the average for the query, which will only use the records
> of the users that have completed the survey. What syntax do I type to point
> to the question 1 field on my query and not on my table?
> Hope this makes sense.
> Any help would be appreciated.
> 
> Many thanks
> 
> Steve
> 
> 
> 


Relevant Pages

  • How do I display averages on a form.
    ... How do I display averages on a form. ... will be set up as follows, Excellent, Good, Average, Poor and Very Poor. ... A query is set up to display all the users that have completed the survey, ... I want to display the average for the query, which will only use the records ...
    (microsoft.public.access.gettingstarted)
  • Re: DB Result Wizard Error
    ... Also noted that one folder, which contains no information can't be deleted, ... >> For instance Equipment Serial Number, Equipment Model Number, Cost Accounting ... >> to display the new equipment information. ... >> is in the table was added to the query. ...
    (microsoft.public.frontpage.programming)
  • RE: Just starting to design a form (or is it a query?)
    ... A Form is used to display the data and allow ... A query can be the record source for a form. ... that match an ID in the Assessment table. ... Now, assuming this is the case, what you need is a form with a sub form. ...
    (microsoft.public.access.gettingstarted)
  • Re: database lookup
    ... the query on the subsequent page, and display the "drill down" data. ... The thing with PHP and MySQL is that you need the user to do an action ... I tried to state that I have the database designed and implemented but I ...
    (alt.php)
  • Re: how to show two rows in an unbound continuous form
    ... Thanks a lot for your prompt response.Actually i thought of using crosstab ... I have created a crosstab query on the table i gave you earlier.The first ... have bound the form's controlsource also,of course). ... clue how to display the second row to show another leave period(01-05-2009 to ...
    (microsoft.public.access.formscoding)