Results 1 to 5 of 5
  1. #1
    Join Date
    May 2013
    Posts
    30

    Unanswered: Report Group Header Count

    Hi, I have a this problem in completing this report where a group header 1 takes the counted row data in Group Header 2.

    Suppose to be the report should look this:
    --------------------------------------------------------------
    --------------------------------------------------------------
    Group Header 1
    --------------------------------------------------------------
    Class_Type Total_Count Percentage
    Electronic Devices 2 25%
    --------------------------------------------------------------
    Group Header 2
    --------------------------------------------------------------
    Device_Type Total_Count Row #
    Phone 10 1
    Headset 11 2
    --------------------------------------------------------------
    IDs 2 25%
    --------------------------------------------------------------
    Group Header 2
    --------------------------------------------------------------
    ID_Type Total_Count Row #
    Supplier 10 1
    Employee 20 2
    --------------------------------------------------------------
    Locker 3 50%
    --------------------------------------------------------------
    Group Header 2
    --------------------------------------------------------------
    Locker_Type Total_Count Row #
    Premium 10 1
    Transient 10 2
    Simple 10 3
    --------------------------------------------------------------
    Report Footer
    Total: 7 100%
    --------------------------------------------------------------

    Now the Group Header 1's Total_Count actually counts the total row number in each Group Header 2s row number. The problem is, I can't get the value of the row number placed in each row of the Group Header 2 (especially the last one counted). Can anyone help me, I would really appreciate it. Thanks...

    A .txt file is attached to make a clear overview...
    Attached Files Attached Files
    Last edited by gone_3am; 07-02-13 at 14:54.

  2. #2
    Join Date
    Nov 2004
    Location
    out on a limb
    Posts
    13,692
    Provided Answers: 59
    either push the count and percentage into the relevant gorup footer OR do the work yourself using domain functions such as DCOUNT, DSUM.
    this can be done by placing two empty text controls in each header
    then in the relevant header on format event place you code that performs the required maffs.

    OR

    use a recordset in place of the domain functions
    I'd rather be riding on the Tiger 800 or the Norton

  3. #3
    Join Date
    Jul 2013
    Posts
    1
    domain function has to be place in record set, try it

  4. #4
    Join Date
    Nov 2004
    Location
    out on a limb
    Posts
    13,692
    Provided Answers: 59
    domain function
    avariable = dcount(the column to be counted,table/queryname, where condition

    recordset
    select count (mycolumn) as countmycolumn, sum(mycolumn) as sumcolumnx from mytable
    group by acolumn
    I'd rather be riding on the Tiger 800 or the Norton

  5. #5
    Join Date
    May 2013
    Posts
    30
    Guys I made it... Thanks alot for help and tips.. By the way I did a lot of math on the group header 2 just to give each rows a group number... TY

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •