Microsoft Dynamics AX 2012 R3 Development-3 Locus IT Services

Microsoft Dynamics AX 2012 R3 Development-3

Locus IT ServicesMicrosoft Dynamics AX 2012 R3 Development-3

Lesson 2 : Data Sources

Data Sources

Data source(s) define the interface between the form and the database. An entry is added for each table. The properties of the individual determine the relationship between the data sources. It also has system methods that can be overridden to control the display of data or act on an event.

It contains all fields in the table. Again, all fields have properties and system methods that can be overridden. These methods control the following functions.

  • Field specific navigation (filter, lookup, jump to main table and more)
  • Validating the field
  • Modifying the field

Use the list of fields as a sources for draganddrop operation when you build the design of the form. You cannot drag fields directly from the underlying table as the form must know which data source the field is linked to.

Field groups display below the list of fields. They can also be used as the source for draganddrop operation.Notice that after accessing the form in the AOT the definition of the data source is cached locally in the definition of the form. If changes are made when you create a new field in the underlying table, you must restore the form to access the new field in the form. Remember to save the form before clicking Restore from the shortcut menu.

A form data source supplies the data that appears on a form. To display data, you assign a data field from the form data source to a property of a control that appears on the form.

You might have X++ code in a form or control that attempts to access field that is not included in the select list of the data source. If the form or a control attempts to access a field that was not retrieved, an X++ exception is thrown. In addition, information about the error is added to the Infolog. To see whether the field is available, use the isFieldDataRetrieved method. You can also add the specified field to the select list of the data source or remove the code that attempts to access the field.

Locus IT Project Management Office
What’s it?