How to create 'Simple list' form in D365

Description:- 

In order to construct Simple List form in AX7, we will first create a table that will be populated from the form and use as data source of the form. To create a new table, first add new item to the project.

 

After clicking new item, it will open the AX7 Artifacts. Select Data model from the left pane and table from the list of artifacts. Give appropriate name to your table.


Table is created now new fields can be added either by dropping EDT's over field node or right click and create new fields. Add fields that are required on the form. These steps are mostly same as in earlier versions of AX. 

New index can also be created in same way. I have created 'Non duplicate' index in my table after adding table fields. 


Next is to create the form again by adding new item in the project. This time we need to select User interface from left pane and select form artifacts from the list.


Give name to the form and select add. This will add new form to the project. After add new datasource in the datasource node and set the table property “dev_EmployeeRecordsData”.


Now the important thing is to apply pattern to the design. It can be done by right clicking the design node of the form and navigate to Apply pattern -> Simple List (As we are building Simple list form so i have selected this pattern, choose patterns you like to add on forms design).

After add the design in the form. Right click on the Design|Pattern after over the Apply pattern and select Simple List design from the list.


After applying the pattern, you can see it automatically gives you the pattern of design which needs to be completed in order to build form design. Make sure there is no missing control on the from design otherwise your project will not be build successfully. New controls can be added by right clicking on design node, hover to new and select appropriate control from the list. 

After that you can see you form design layout in the below (pattern) panel.


For Simple List form, we need to add following controls on it:

1. Action pane and Action pane Tab
After adding action pane and tab, we also need to add command buttons of ADD and DELETE same as we   do in earlier versions. 

2. Custom Filter Group
Custom Filter group needs to be added on this form to filter the form data. One issue i faced while adding custom group on design is that we also need to apply sub Patterns on it otherwise it won’t work. Patterns can be applied in same way as we did on design node.  

After that click on the design|Pattern and over New and select the Action Pane from the list.


After that click on the design|Pattern and over New and select the Group from the list.


After that select the added group (FromGroupControls1) and right click on it over apply pattern and select custom and quick filters.


After again right click on the Group (FromGroupControls1) control and over new then select the QuickFilter from the list.


3. Finally we need a grid control on the form to display, edit and insert data on the form. 
So after adding all controls we can see that pattern shows no missing control.

After that right click on the Design|Pattern and over New then select the Grid from the list.


In the below pattern pane you can see there no controls missing to add.


As form also need some data source, so we will drag and drop the table created earlier on form data source. Now drag and Fields from the DataSource to form Grid.


This completes our table and form creation. In order to show above form in Fleet management area page, we need to create a display menu item of the form. Follow the same steps we did for form creation just need to select Display Menu Item artifact from list.


After change the Display menu item property like object.


Set the startup object and build you project and run it. Here is how this form looks like in UI. Or else you want to set in existing menu the create extension for that menu from AOT and drag in that where you want to place you display menu item.


After that drag you Display Menu Item from the Solution Explorer to menu item like below image.


After that build the solution and open your dynamics ax application on the Internet explorer. Go to the navigation pane and select Umesh Practice on that select Employee records form like below.


Fill the records like below.

Related Posts

Previous
Next Post »