Prevent AX Reports from Auto-Sending via Outlook Email

Requirement: When choosing email as the report destination in, allow the user to edit the email contents in Outlook rather than automatically sending.

A number of users have been concerned that outlook automatically sends email destination reports, rather than allowing them to first modify or verify the email, subject and addresses in a “new email” window.

Solution: To fix this you can modify the “SRSReportRunMailer.emailReport” method. Depending on your version of AX, modify the section around line 41 as below.

 

 

Allow non editable table fields to be modified via AIF.

Requirement: Allow requests made via AIF to modify fields with the table field property “AllowEdit” set to NO to be modified. By default if you modify a field in a service call that is non editable no errors occur but the field is not updated.

Solution: On your AXD service contract class, right click on the class , click “Override method” choose method “initFieldAccessOverrides” to override. Append the following line to the method

this.overRideFieldAccess(tableNum([YourTable]), fieldNum([YourTable], [YourField]), AxdFieldAccess::AllowEdit, NoYes::Yes);

Note: This can also be used to override the “editOnCreate” property of a table field for AIF usage.