?
Solved

crystal reports

Posted on 2004-11-17
2
Medium Priority
?
238 Views
Last Modified: 2012-05-05
I am trying to get the avg grade in a winform using vb.net and crystal reports.  Below is the code that I have tried that does not work.  How do I find the avg of 3 rows in a crystal report?

{student.grade1} + {student.grade2} + {student.grade3} / 3
this code does not avg the grade

Average ({student.grade1} + {student.grade2} + {student.grade3} / 3)
this one is asking for a required field at the end


0
Comment
Question by:freebird317
2 Comments
 
LVL 21

Accepted Solution

by:
MogalManic earned 750 total points
ID: 12611357
To compute an average, you need to to the addition first.  Use this expression:
  ({student.grade1} + {student.grade2} + {student.grade3}) / 3


Without the parentheses around the addition, the division is performed 1st and then the other two student grades are added.
0
 
LVL 101

Expert Comment

by:mlmcc
ID: 12611930
Are the grades in the same record?

if not then
Add a group on the student
Use a summary function - Average and the grade field as the data.

mlmcc
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this post we will learn how to connect and configure Android Device (Smartphone etc.) with Android Studio. After that we will run a simple Hello World Program.
Today, the web development industry is booming, and many people consider it to be their vocation. The question you may be asking yourself is – how do I become a web developer?
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …
Introduction to Processes

850 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question