Показать сообщение отдельно
Старый 13.09.2017, 17:11   #1  
Blog bot is offline
Blog bot
Участник
 
25,475 / 846 (79) +++++++
Регистрация: 28.10.2006
Art Of Creation: Workflow: An unexpected error has occurred while opening the workflow. See the event log on the AOS and contact your system administrator to resolve the issue.
Источник: http://www.artofcreation.be/2015/08/...lve-the-issue/
==============

When trying to view or edit a workflow, the following error can pop up:
An unexpected error has occurred while opening the workflow. See the event log on the AOS and contact your system administrator to resolve the issue.

This is a general error and it could mean a lot of things. Make sure you check the obvious things first:
  • Make sure that the build number of the client maches the build number of the server
  • Make sure x++ compilation has been done on the AOT
  • Make sure CIL is compiled without errors
  • Do a data dictionary synchronization
  • Refresh the WCF configuration using the Dynamics AX 2012 Configuration utility
  • Remove the AUC files and KTI files from the %localappdata% directory
  • Remove usage data
Well… you know… do the usual.

In my case, none of this helped. Because this was a CLR exception, I modified the try/catch in the method that was throwing the error to show the inner exception. The method Forms\WorkflowEditorHost.run was modified so it looked like this:

<div class="codecolorer-container xpp default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="xpp codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">public void run()
{
System.Exception interopException;

try
{
modelEditorControl.Load(workflowConfiguration, userSettings); <span style="color: #007f00;">//
__________________
Расскажите о новых и интересных блогах по Microsoft Dynamics, напишите личное сообщение администратору.