NAV RDLC Reports: Using Dataset for Totaling Value Fields

Sigita
Member Posts: 6
I found out that seeing the Dataset of a report can be very helpful, because it shows all values for every Data Item‘s column in one table.
Watch this video (https://www.youtube.com/watch?v=7-IpaGa6aCw) to see how the Dataset can be opened for reports in NAV.
It‘s useful to export this table to Excel and, with the help of filters, see how particular values are calculated. It is less time-consuming than adding test messages to the code or test controls in Layout. Most often, I use the Dataset Table to check total values. If the report was transformed using Partner Zone Report Transformation Service and function CurrReport.CREATETOTALS was used in that report, then you may have to take some actions to re-implement that functionality. The three things I do to re-implement the CurrReport.CREATETOTALS function are:
1.Use the function SUM in Visual Studio Textbox expression (i.e. =SUM(Fields!Sales_Invoice_Line__Amount.Value) )
2.Use the function LAST in Visual Studio Textbox expression (i.e. =LAST(Fields!Sales_Invoice_Line__Amount.Value) )
3.Create new Global Variables in NAV and use them in C/AL code to count the total values. Then add those Global Variables as a Column in adequate data item and use them in Visual Studio as a source expressions.
There is no straightforward rule to identify which of these three options should be selected. If, after transforming your report using Partner Zone Transformation Service, the total fields in your report are not calculated correctly, I would recommend to open the Dataset of your report, check how the total values are calculated, and then decide which of these three options are suitable in your case.
BTW, here you can read more about Partner Zone Transformation Services:
http://1clickfactory.com/partner-zone/1 ... sformation
Watch this video (https://www.youtube.com/watch?v=7-IpaGa6aCw) to see how the Dataset can be opened for reports in NAV.
It‘s useful to export this table to Excel and, with the help of filters, see how particular values are calculated. It is less time-consuming than adding test messages to the code or test controls in Layout. Most often, I use the Dataset Table to check total values. If the report was transformed using Partner Zone Report Transformation Service and function CurrReport.CREATETOTALS was used in that report, then you may have to take some actions to re-implement that functionality. The three things I do to re-implement the CurrReport.CREATETOTALS function are:
1.Use the function SUM in Visual Studio Textbox expression (i.e. =SUM(Fields!Sales_Invoice_Line__Amount.Value) )
2.Use the function LAST in Visual Studio Textbox expression (i.e. =LAST(Fields!Sales_Invoice_Line__Amount.Value) )
3.Create new Global Variables in NAV and use them in C/AL code to count the total values. Then add those Global Variables as a Column in adequate data item and use them in Visual Studio as a source expressions.
There is no straightforward rule to identify which of these three options should be selected. If, after transforming your report using Partner Zone Transformation Service, the total fields in your report are not calculated correctly, I would recommend to open the Dataset of your report, check how the total values are calculated, and then decide which of these three options are suitable in your case.
BTW, here you can read more about Partner Zone Transformation Services:
http://1clickfactory.com/partner-zone/1 ... sformation
Developer at 1ClickFactory
0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions