D365FO. “The authentication process was not successful. Please contact your system administrator.” error during Connect to Lifecycle Services setup.

As we know, there are hundreds of task recordings available out of the box in LCS library. Before first use, system administrator should authorize D365FO to access LCS and often it is not possible due to the old bug. When system administrator goes to Settings -> Task recorder -> Play recording as guide -> Open from Lifecycle Services and clicks “Select the Lifecycle Services library” “Connect to Lifecycle Services” dialog pops up.

Connect to Lifecycle Services

There is a link “Click here to connect to Lifecycle Services” and when administrator clicks on it he may receive “The authentication process was not successful. Please contact your system administrator.” error.

It’s is caused by empty value of “LCS.GettingStartedLibrary” parameter in web.config file.

To fix it go to K:\AosService\WebRoot and edit web.config file. Find LCS.GettingStartedLibrary tag and set value to any integer that is greater than 0, save file and restart IIS. Don’t forget to backup web.config before doing any changes.


Probably LCS should put BPM library id there, however, it works with any random positive integer as well. To find BMP project id, go to LCS, open your project and click on “Business process modeler” tile. Then select library that contains task recording.  In the URL of the page grab value of FWK parameter


Hopefully, this bug will be fixed soon and we won’t have to play with web.config file anymore.


D365FOE. Issue with enums that have “Use Enum Value” property set to “No”.

Recently we have noticed incorrect behavior of enums that have “Use Enum Value” set to “No” and have gaps in enum values. These enums use values from properties when populated from user interface, however, X++ code uses generated values, that cause inconsistent behavior and data corruption.

To illustrate this issue, we will create new enum with two values: 0 and 10. Also we need to set “Use Enum Value” property to “No”.







Also, we need simple table that has only one field, form to populate this field from UI and job to create data from X++.





Runnable class:


Let’s run the class and check data in DB and UI.

In DB value is equal to value from enum properties – 10:


On the form we can see empty value:


Let’s create new record using UI and check what is saved to DB.



As you can see, value is equal to 1. For these enums value entered from UI will never be equal to value entered from X++ code, so if it is created in X++ user would see empty values, if it is created from UI X++ comparison like:

If (myTable.MyEnum == MyEnum::Ten)  

would always return false, even if user see “Ten” on UI, because values are different.

It was a common practice to have gaps in enum values for different layers, so you could avoid conflicts when new values are created in new version or a hotfix. AssetTransType is a good example, where localization related values start from 100, because they used to be on another layer.

However, most of standard enums use enum values, so probably that is why this bug was not spotted before.

As a good citizen, I filled a bug, but I have a sneaky suspicion that it won’t be fixed soon, so be aware of this volatile mix, try to avoid changing “Use Enum Value” property and review your enums in case you have one!

Query::insert_recordset() ignores XDS policy.

Recently we did a customization to create custom XDS policy and found out that Query::insert_recordset() ignores it, so all data is selected.

Simple workaround is to rewrite Query::insert_recordset() to while(queryRun.Next()).

However no one really wants to modify bunch of standard code that uses this method so connect issue was created. Feel free to vote for it.

It could be reproduced in AX 2012 and AX 7 as well.