AXForum  
Вернуться   AXForum > Microsoft Dynamics AX > DAX Blogs
All
Забыли пароль?
Зарегистрироваться Правила Справка Пользователи Сообщения за день Поиск

 
 
Опции темы Поиск в этой теме Опции просмотра
Старый 09.09.2012, 14:11   #1  
Blog bot is offline
Blog bot
Участник
 
25,475 / 846 (79) +++++++
Регистрация: 28.10.2006
sumitsaxfactor: Build and Deploy Simple Report–Queries
Источник: http://sumitsaxfactor.wordpress.com/...reportqueries/
==============

In this post, I will explain about creating a simple AX SSRS Report using the queries from AX AOT. This is what you need to do:
  • Login to AX and open the development workspace
  • Go to AOT –> Queries, right click and select “New Query”
  • Rename the query to “SKL_SampleCustomer”
  • Go to Query’s data source node and right click and select “New Data Source”
  • Rename the data source to “CustTable” and set property table to “CustTable”
  • Now go to the “Fields” node of this query and set property: Dynamic to “Yes”
  • The query looks as shown below

  • Save the query
  • Now open visual studio and create a new reporting project by name SKL_SampleReportProject
  • On the reporting model, right click, select “Add” and then Report
  • This will add new report to the project

  • Name this report as “SKL_SampleSimpleReportQuery”
  • In the report, Right click on the Dataset node and select “Add Dataset”

  • Name the data set as customer
  • On the properties window, ensure following properties are set by default

  • In the query property, click the button
  • This opens up the query selection box to select a Microsoft Dynamics AX Query
  • From the list select “SKL_SampleCustomer” and click Next

  • Here you can select required fields. Either you can select all fields or a subset
  • Expand All Fields nodes under the CustTable node to select “AccountNum”
  • Expand Node “All Display Methods” and select “name” and “openBalanceMST”
  • Click “Ok”





  • This will generate the required fields for the dataset

  • Now Right click on the designs node, select Add and then “Auto Design”. This creates a new Auto Design and name it as Report

  • Select a layout template say “ReportLayoutStyleTemplate”

  • Now right click on newly created design select “Add” and “Table”

  • Set following properties
    • Name – Cust
    • Dataset – Customer
    • Style Template – TableStyleAlternatingRowsTemplate
  • You will also notice that the fields are included automatically from Dataset to the “Data” node of the table

  • Click on Preview once to view the report


Note: It may not be possible to preview all reports from VS, especially when there are some internal parameters etc.
  • Now right click on the report model and select option “Add SKL_SampleReportProject to AOT”

  • Once the report is added, go to AX, find the report in AOT –> SSRS Reports –> Reports, right click and deploy using “Deploy Element” option
  • Once the deployment is successful, create an output type menu item for the report
  • Go to AOT –> Menu Items –> Output, Right click and select “New Menu Item”. Set following properties

  • Now using menu item open and run report.
When you open the menu item, a dialog is automatically made and shown and you will notice that there is also a select button











This happens as we had kept the Dynamics Filter property on Dataset in report to “True”. Hence the Reporting framework adds a select button.

The displaying of dialog box can be handled as well. We will cover this topic when we learn about controller classes.

The report will look like this:




Note: The name has been intentionally removed from image

Hope this helps you in building your first simple report.




Источник: http://sumitsaxfactor.wordpress.com/...reportqueries/
__________________
Расскажите о новых и интересных блогах по Microsoft Dynamics, напишите личное сообщение администратору.
 

Похожие темы
Тема Автор Раздел Ответов Посл. сообщение
emeadaxsupport: AX 2012 reports fail to deploy on a server hosting multiple SQL Server Reporting Server instances Blog bot DAX Blogs 0 15.06.2012 11:11
dynamicsaxbi: Collections: Report Developer Resources Blog bot DAX Blogs 0 10.03.2012 16:12
Jim Wang: Fetch-based report, Sandbox and TCP 808 Blog bot Dynamics CRM: Blogs 0 29.09.2011 05:18
paruvella: Displaying SSRS report in Ax-EP page Blog bot DAX Blogs 0 02.02.2010 21:05
axStart: Date methods in your Visual Studio Dynamics AX Report. Blog bot DAX Blogs 0 10.09.2008 23:05

Ваши права в разделе
Вы не можете создавать новые темы
Вы не можете отвечать в темах
Вы не можете прикреплять вложения
Вы не можете редактировать свои сообщения

BB коды Вкл.
Смайлы Вкл.
[IMG] код Вкл.
HTML код Выкл.
Быстрый переход

Рейтинг@Mail.ru
Часовой пояс GMT +3, время: 12:01.
Powered by vBulletin® v3.8.5. Перевод: zCarot
Контактная информация, Реклама.