Wizards and Rules Issues
Troubleshooting issues and workarounds for K2 wizards and rules.

Issue:
When troubleshooting Word document conversion issues, error code messages have no additional details. There are, however, additional error details in the SharePoint database server.
Resolution:
To find the matching error message, do the following:
-
On your SharePoint database server, find the Word automation database. If it was created by default, it would be named something like WordAutomationServices_7a95f9714da6478ca60a03173db67eb6.
-
Open the Items table, look for the relevant item and check the errorCode column.
-
Compare the error code to the table below, or follow this link: http://msdn.microsoft.com/en-us/library/ff512774.aspx

Issue:
The following error may be encountered when the CRM wizard is dragged onto the design canvas in K2 Studio or K2 for Visual Studio. The wizard's welcome screen will be displayed and the user can select NEXT, however, the error below will appear. The only option is to cancel the wizard.
In K2 Designer for SharePoint, the following error is displayed:
Resolution:
-
Install Microsoft Dynamics CRM 4.0 SDK available at http://www.microsoft.com/downloads/en/details.aspx?FamilyID=82e632a7-faf9-41e0-8ec1-a2662aae9dfb&displaylang=en on to the server.
-
Add the Microsoft.Crm.Sdk.Dll and the Microsoft.Crm.SdkTypeProxy.Dll to the Global Assembly Cache (GAC).

Issue:
If the Plan per slot (no destinations) destination rule has been selected and multiple slots are created, the activity should only complete once all slots have completed. However, this is not always the case. An activity will complete once the first slot has completed, even though the remaining slots are reflected in reports (with empty status values). To prevent the activity from completing if there is more than one slot, it is important to define additional succeeding conditions that ensure that the activity completes only after all slots have completed.
Scenario: Process with IPC event
One example is a process that uses a filtered SmartObject Getlist method in the destination rule, to asynchronously kick off X number of sub process instances using an IPC event.
Notice that multiple slots are created with the return of the Getlist method. The destination rule is configured to start the IPC event asynchronously, which in effect means that the parent process starts the child process and continues down its logical path.
Explanation:
As soon as the first slot is complete, the parent process will continue down its logical path, leaving the remaining slots in limbo.
Resolution:
Add a succeeding rule that checks whether all slots have been completed before continuing with the activity. Below is an example of a succeeding rule that checks the slot status.

Issue:
Host headers are not supported with forms generation in K2 blackpearl. Using host headers with forms generation will cause the client ASPX page created by the forms generation wizard to display the following errors when launched:
Resolution:
A developer with administrator rights on the IIS machine where the newly created forms generation website is hosted must create a web application out of the newly created gorms generation virtual directory in IIS.

Issue:
Logically, an activity completes when all tasks/events associated with the activity have been completed. It is easy to assume that the succeeding rule will prevent the process from continuing.
Do not rely on the process to continue because all events have been completed. Plan the process logic carefully and use a combination of succeeding rules and line rules.
The logic of the succeeding rule should be interpreted in the context of all completing conditions:
(Activity completes) IF (Defined succeed conditions(Activity)=TRUE) OR (All events complete(Activity)=TRUE)
Scenario: Student Admission
Students are admitted to the School of Management based on a board review of their application. The approval decision can be either approved, declined or pending.
The succeeding rule requires that:
-
A minimum of 3 board members approve the admission.
-
A minimum of 2 board members decline the admission.
-
All the board members must lodge a decision other than pending for the 'Approve Application' activity to complete.
However, the Approve Application activity completes even if a decision of pending is recorded.
Explanation:
The All Events Complete criteria of the succeeding rule evaluates to TRUE and the Approve Application activity completes, even if some of the board members record the approval decision as pending.
Resolution:
Option 1: Remove pending from the options for the approval decision.
This is a simple solution but may not provide the flexibility required. Be sure to modify the succeeding rule.
Option 2: Handle the pending outcome for the Approval Decision specifically.
Understand why the approval decision could be pending, for example, the application is not complete and needs more information. The process could loop back to collect more information. Be sure to check the line rules to cater for all the scenarios.
Recommended Practice
- Always define a succeeding rule when there are more destination users than destination slots.
- Use line rules to direct the flow of the process when there is a destination slot for each destination user.

Issue:
The following error may be encountered when trying to perform a Word document conversion:
Unrecognized attribute ‘allowInsecureTransport’
Resolution:
This issue mostly occurs when SharePoint 2010 is installed on a Windows 7 or Windows Server 2010 R2 machine.
If you encounter this error, installing the following Microsoft patch should resolve the error: