Showing posts with label Workflows 2013. Show all posts
Showing posts with label Workflows 2013. Show all posts

Wednesday, 15 July 2015

Workflow 2013 custom activity not visible in toolbox

Did you create custom workflow activity in a project different from workflows project?
Are they in different namespaces?
Is the custom created activity not displayed in toolbox even for the same SharePoint Site?
 


The custom workflow activity project needs to be deployed explicitly in GAC for the workflows to identify. To confirm this create string name key for the project, open the Visual Studio command prompt and register the dll in GAC.

Instead of manual effort the same can be done as part of the SharePoint packaging itself. Follow the below steps to do it:


1. Right click the Custom workflow project and select Properties
2. Set the 'Include Assembly in package' to "False". This is true by default
3. Go to Package.package file and select "Advanced" tab
4. 3 assemblies need to be added here
  •  Click on 'Add existing assembly'
  •  Select "\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\IDE\PublicAssemblies\Microsoft.SharePoint.DesignTime.Activities.dll"
  •  Select "\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\IDE\PublicAssemblies\Microsoft.SharePoint.DesignTime.Activities.Design.dll"
  • Click on "Add from Project Output"
  • Select the dll of workflow custom activity

5. Add the reference of this assembly to the workflows project
6. Restart the visual studio instance containing workflows project
7. Now the custom workflow activity created should be available in the toolbox
 

Monday, 30 March 2015

Workflows communication exception

I had deployed a workflow wsp using powershell and while activating a feature, I received an exception in browser:

Microsoft.Workflow.Client.WorkflowCommunicationException: The request was aborted: The request was canceled. Client ActivityId : <<guid>> ---> System.Net.WebException: The request was aborted: The request was canceled.


Though all services were running, workflow manager was connected; there was no clue why this happened. Just by resetting the IIS, the issue got solved.