Need Help with Aggregate of Aggregate in Visual Studio Report RRS feed

  • Question

  • I'm new to reports and need help with this:

    I'm building a RDLC report to display with a reportviewer on my page.

    The report I was successfully able to create looks like this:


    The datasource is a list of objects that each contain employee's working time:

    Datum (Date)

    Arbeitsstation (Workstation)


    Eingang (EntryTime)

    Ausgang (ExitTime)

    Gearbeitet (Time Worked)

    I was able to get the subtotals in each group (Date/Workstation/Name), hide the duplicate details and even display "Fehler" (Error) when there were missing times and the subtotal could not be figured out.

    As you can see, I display a subtotal for each day that an employee had working times.

    Here's what I haven't been able to figure out: At the end of the report, I want to display a grand total of all the working times for each employee. I want it to look like this (sample data, since I did not include whole report):

    Avi dws            Total: 54 Std 28 Min

    Chana Winkler Total: 48 Std 21 Min

    I've tried adding a new table below my original report with only the Name and the sum of the time worked in the details row and a group on Name and hiding duplicate names. But it shows all the employee's names for each day that they worked. I need it to aggregate the days into one grand total at the end.

    How do I do this? THANK YOU!

    • Edited by CWinks Sunday, September 1, 2013 10:14 AM
    Sunday, September 1, 2013 10:14 AM

All replies

  • you can add grand total in table footer

    Please mark this reply as the answer or vote as helpful, as appropriate, to make it useful for other readers

    Sunday, September 1, 2013 10:20 AM
  • Okay, that's what I want to do. But how? Could you give me the expression to write into the footer?

    Thank you!

    Sunday, September 1, 2013 10:25 AM
  • This is what I have in the footer's textbox expression:


    where "formatTimeSpan" is a custom code that just puts the TimeSpan into the correct string.

    What I get is

    Chana Winkler        4 Std 0 Min

    I would need a list of all employees and the total of their hours.

    Please advise!!

    • Edited by CWinks Sunday, September 1, 2013 11:49 AM
    Sunday, September 1, 2013 11:48 AM