I am trying to calculate the Grand Total for my Order Items on my main order form using the SUM(). It displays on the subform itself but error s out on the main form. I find it hard to figure out where I went wrong after many days and my Acces skills are really beginner. Solutions suggested in the link bellow have not solve the problem. =SUM([Quantity]*[Price]) or =SUM(NZ([Amount],0))
OrderID is the PK in the order form and orderDetailID is the PK in the Order Details form.
Any Help would be highly appreciated MS Access Subform with fields with #Error in form view
Reviewed your db posted in other forum. You must have made some changes because I don't get the behavior you describe. The only time #Error shows is when there are no records in the subform. This should be expected. Instead of showing the subform total on the main form, could just have the sum show on the subform. With the mainform/subform in Form view (not Design view), click into the subform then click the Sum (looks like Sigma) button on ribbon. This will open the Total row on the subform. Or set the subform for Continuous and arrange controls to look like Datasheet.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.