Update Document Service Form

Applies To: Microsoft Dynamics AX 2012 R2, Microsoft Dynamics AX 2012 Feature Pack, Microsoft Dynamics AX 2012

Tools > Application Integration Framework > Update document service

Use this form to update an existing document service.

This form enables you to add new service operations to a document service class. You can also regenerate the data objects and the Ax <Table> classes (also known as AxBC classes).

Note

You can only add service operations to a document service class in this form. If you want to delete service operations, you must do so manually.

This form is useful when you want to add functionality to a document service class. For example, if you have a document service that supports only the ability to read and find data, you may want to enable that service to update and create data. In this case, you can use this form to add the update and create service operations to the existing service.

Note

This form only updates service classes. If you add a service operation, you must set the permissions for the new method in the Application Object Tree (AOT).

This form is also useful when you make a change to a table, for example, if you add a field to a table, and you want that change to be reflected in the document service classes. In this case, you would select Regenerate data object classes and Update AxBC Classes to add the new field to these classes.

The following tables provide descriptions for the controls in this form.

Buttons

Button

Description

OK

Update the document service class and the associated data classes.

Cancel

Exit without updating the service.

Fields

Field

Description

Service class name

Select the document service class that you want to update from the dropdown list.

create

Select this field to add the create service operation.

read

Select this field to add the read service operation. If a table in the service query contains date effective fields, readAsOf and readRange service operations will be added.

update

Select this field to add the update service operation.

delete

Select this field to add the delete service operation.

find

Select this field to add the find service operation. If a table in the service query contains date effective fields, findAsOf and findRange service operations will be added.

findKeys

Select this field to add the findKeys service operation. If a table in the service query contains date effective fields, findKeysAsOf and findKeysRange service operations will be added.

Regenerate data object classes

Select this field to regenerate the data object classes including the document data object and the associated data objects.

Update AxBC Classes

Select this field to update the Ax <Table> classes.

Note

If you remove a field from a table and then use this form and select Update AxBC Classes, the parm <Method> associated with the field that you removed from the table will not be removed from the Ax <Table> class. This is so that customized code is not automatically removed from the Ax <Table> class. You must remove these methods manually. For example, if you removed Field1 from Table1, you must manually remove the parmField1 method from the AxTable1 class.

Update the Actions in the AOT

After you update a document service class with a new action, that action is available from the service class but it is not available to external callers. In order to use that action, you must then expose the new action as a service operation as shown in the following steps:

  1. Open the AOT and expand the Services node.

  2. Navigate to the service class and expand the Operations node. You will see that the new action you added in the Update document service form is not listed.

  3. Right-click the Operations node and select Add Operation. A dialog appears that lists the service class methods that are not currently exposed as operations.

  4. Select Add for the new service class method listed in the Operation method name field and then click OK.

  5. Press CTRL+S to save your changes.