Group by totals in a subform

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • laguerin
    New Member
    • Feb 2010
    • 3

    #1

    Group by totals in a subform

    I have a subform within a form that lists detail records for a specific account that is selected by a combo box in the forms header. The records contain the type of records (A01, A02, D01, D02 etc and there could be multiple A01, A02 etc), another defining code and an amount for each. My question is, can one add up all the A01's and display a sub total, then the A02s and list a sub total etc in a continous bound access form? I know you can do this in a report but how about a subform?

    For example

    A01 AA $10.00
    A01 BB $30.00
    A01 DD $25.00
    A01 $65.00
    A02 AA $20.00
    A02 BB $5.00
    A02 $25.00
  • mseo
    New Member
    • Oct 2009
    • 183

    #2
    As I understood from you, the items (A01AA, A02 BB, ... etc) can be considered as products, but not so, the point i want to clarify
    it seems like you have a lot of records with a lot of different items to the extent that you can't get the sub total of each, is that right?
    you can create new subform and set its query to get the subtotal of the items in the subform that you have

    Comment

    • laguerin
      New Member
      • Feb 2010
      • 3

      #3
      Originally posted by mseo
      hi,laguerin
      as I understood from you, the items (A01AA, A02 BB, ... etc) can be considered as products, but not so, the point i want to clarify
      it seems like you have a lot of records with a lot of different items to the extent that you can't get the sub total of each, is that right?
      you can create new subform and set its query to get the subtotal of the items in the subform that you have
      hope this helps
      let me know if I can submit further help
      Thanks for the response.
      What the user wants is to mirror what they now have when they create an excel spreadsheet. They produce a worksheet with columns of sorted data and within the sheet they insert a row and add up the those specific records then continue with the next set of records. I guess maybe "insert" is a better way to ask if this can be done. Will this new subform's total be inserted after each specific group's data?

      Comment

      • NeoPa
        Recognized Expert Moderator MVP
        • Oct 2006
        • 32669

        #4
        The answer is that you cannot do it directly in a form. The only headers/footers available are Page & Form ones, and it's Group ones you'd want for this.

        That said, MSEO's suggestion of inserting a sub-form may be possible to get to work. I'm not very experienced at that level in forms to be honest. If not, then I don't see it can be done at all.

        Comment

        • laguerin
          New Member
          • Feb 2010
          • 3

          #5
          Thanks for all your help. I'll give it a try. Maybe this could be an enhancement of Access in the future!

          Comment

          Working...