Sunday, September 21, 2014

Form datasource

What is form datasource

Form datasource is a data source (source) of the form. The forms are displaying the database table records to the end user by using the form datasource. For example, if you open the vendor list screen, the form will display the vendors list by fetching records from the database VendTable table. Here VendTable is the form datasource.

The form displays the datasource fields. Type of form datasources are AOT query, table and view. The form has two types of controls that are bound controls and unbound controls. Bound controls are linked with form datasource fields, but unbound controls are not related with form datasource fields. The form datasources are having link with database. So, it is having connection with database. It supports form to add, edit and delete the records.

Types of form datasources

  1. AOT Query
  2. Tables

Add datasource to the form

In AX, It is very easy to display or update or delete the records in forms. It is very simple. Follow the below steps to display the records in the grids.
  1. Add new form
  2. Click and drag a table to form datasource node or right click on the form datasource and click new datasource and select the table name in table property of the newly added form datasource
  3. Add grid control in the form design node
  4. Click and drag the newly added form datasource table fields to grid control

We can control the forms to add, edit and delete the form datasource records by using the AllowCreate, AllowEdit and AllowDelete form datasource properties. For example, if you want to only display the records but don’t allow the user to create, update and delete the records then please set “No” value to the form datasource properties AllowCreate, AllowEdit and AllowDelete.

Please refer the below screenshot

No comments :

Post a Comment