Sign In Start Free Trial
Account

Add to playlist

Create a Playlist

Modal Close icon
You need to login to use this feature.
  • Microsoft Dynamics AX 2012 R3 Reporting Cookbook Update
  • Toc
  • feedback
Microsoft Dynamics AX 2012 R3 Reporting Cookbook Update

Microsoft Dynamics AX 2012 R3 Reporting Cookbook Update

By : Agarwal, Aggarwal, Elangovan
4.4 (7)
close
Microsoft Dynamics AX 2012 R3 Reporting Cookbook Update

Microsoft Dynamics AX 2012 R3 Reporting Cookbook Update

4.4 (7)
By: Agarwal, Aggarwal, Elangovan

Overview of this book

Microsoft Dynamics AX 2012 R3 Reporting Cookbook is recommended for Dynamics AX developers and .NET-based SSRS developers looking to familiarize themselves with the new AX reporting framework.
Table of Contents (12 chapters)
close
11
Index

Adding a datasource through business logic


This recipe will show how a simple datasource can be created and used as a source of data through the business logic option in reports.

Getting ready

This recipe requires that you have access to Visual Studio with the Dynamics AX reporting extension.

How to do it...

  1. Create a new reporting project called PktExchRateReports in Visual Studio.

  2. Add a report and name it PKTExchRateDataTable.

  3. Right-click on the Data Method node and create a new method as shown in the following screenshot:

  4. Double click the TestMethod node. This adds a new C# project to the solution and a C# class with the same name as the report.

  5. Replace the empty data method with the business logic shown here:

    [DataMethod(), PermissionSet(SecurityAction.Assert, Name = "FullTrust")]
    Public static DataTable ExchangeRateDataset(string _stest)
        {
    DataTable dt;
    // Adding rows and columns in DataTable 
    dt = new DataTable();
    dt.Columns.Add("Category", typeof(string));
    dt.Columns.Add("Base Currency...

Unlock full access

Continue reading for free

A Packt free trial gives you instant online access to our library of over 7000 practical eBooks and videos, constantly updated with the latest in tech
bookmark search playlist font-size

Change the font size

margin-width

Change margin width

day-mode

Change background colour

Close icon Search
Country selected

Close icon Your notes and bookmarks

Delete Bookmark

Modal Close icon
Are you sure you want to delete it?
Cancel
Yes, Delete