{"id":208,"date":"2012-11-07T11:06:17","date_gmt":"2012-11-07T11:06:17","guid":{"rendered":"https:\/\/www.harepoint.com\/Blog\/?p=208"},"modified":"2019-09-24T13:45:03","modified_gmt":"2019-09-24T13:45:03","slug":"sharepoint-custom-actions","status":"publish","type":"post","link":"https:\/\/www.harepoint.com\/Blog\/sharepoint-custom-actions\/","title":{"rendered":"SharePoint custom action: pro and con\u200b"},"content":{"rendered":"\n<p>SharePoint workflow is a very convenient way to solve automation tasks without programming. However, at any step aside from common tasks such as document approval workflow, developers face insufficient functionality of workflow actions delivered with the product.<\/p>\n<p>A full list of workflow actions and conditions delivered with SharePoint 2010 can be found here:<\/p>\n<ul><li><a href=\"https:\/\/support.office.com\/en-us\/article\/workflow-actions-in-sharepoint-designer-2010-a-quick-reference-guide-5a7ad276-0ed7-49b0-b652-e56a77dd96c6\" rel=\"nofollow\">Workflow actions in SharePoint Designer 2010: A quick reference guide<\/a><\/li>\n<li><a href=\"https:\/\/support.office.com\/en-us\/article\/workflow-conditions-in-sharepoint-designer-2010-a-quick-reference-guide-d8e33ac7-9336-487f-a60b-388c4ea497ff\" rel=\"nofollow\">Workflow conditions in SharePoint Designer 2010: A quick reference guide<\/a><\/li>\n<\/ul>\n<p>The problem of insufficient functionality can be solved in the following ways.<\/p>\n<ol>\n<li>To abandon declarative workflow in favor of Visual Studio workflow. In this case, all Windows Workflow Foundation actions will be available for workflow development. However, it\u2019s the worst possible way to solve the problem, as Visual Studio workflow can\u2019t be edited in SharePoint Designer, and development itself is difficult and time consuming. <\/li>\n<li>The second way is to use one of third-party sets of workflow actions. Our product, <a href=\"\/Products\/HarePointWorkflowExtensions\/Default.aspx\"><b>HarePoint Workflow Extensions<\/b><\/a>, offers <a href=\"\/Products\/HarePointWorkflowExtensions\/ListActivities.aspx\">over 300 new activities<\/a> that allow solving most practical tasks.<\/li>\n<li>The third way is to develop a custom workflow action in Visual Studio, which can be used in declarative workflows.  It\u2019s a reasonable step. Though for development, you\u2019ll need a highly qualified programmer, a developed custom action can be used by any competent IT specialist working with SharePoint Designer.<\/li>\n<\/ol>\n<p>For beginners, we have good and bad news. Let\u2019s start with the bad. To develop a custom action, one needs SharePoint installed on the workstation. The good news is that SharePoint can be installed on Windows 7 and even on Windows Vista. This article describes how to do it: <a href=\"https:\/\/docs.microsoft.com\/en-us\/sharepoint\/dev\/general-development\/set-up-a-general-development-environment-for-sharepoint\" rel=\"nofollow\">Setting Up the Development Environment for SharePoint 2010<\/a><\/p>\n<p>SharePoint 2010 custom workflow actions can deploy both farm solutions and sandbox solutions. From the developer\u2019s prospective, the difference between them lies in limitation of the SharePoint object model. Besides, additional restrictions for using namespaces are applied to sandbox solutions deployed in SharePoint Online. Detailed information on these issues can be found in the following articles:<\/p>\n<ul>\n<li><a href=\"https:\/\/docs.microsoft.com\/en-us\/previous-versions\/office\/sharepoint-server-2010\/ee721992(v=office.14)\" rel=\"nofollow\">Sandboxed solutions overview (SharePoint Server 2010)<\/a><\/li>\n<li><a href=\"https:\/\/docs.microsoft.com\/en-us\/previous-versions\/office\/developer\/sharepoint-2010\/gg454741(v=office.14)\" rel=\"nofollow\">Developing SharePoint Online Solutions<\/a><\/li>\n<\/ul>\n<p>The rest of the process of creation and deploying actions doesn\u2019t differ and one of the following articles can be selected as a guide:<\/p>\n<ul>\n<li><a href=\"http:\/\/sundarnarasiman.net\/2010\/12\/26\/develop-custom-workflow-activity-for-sharepoint-2010-workflow\/\" rel=\"nofollow\">Develop Custom Workflow Activity for SharePoint 2010 Workflow<\/a><\/li>\n<li><a href=\"https:\/\/docs.microsoft.com\/en-us\/previous-versions\/msp-n-p\/ff798499(v=pandp.10)\" rel=\"nofollow\">How to: Create a Sandboxed Workflow Action<\/a><\/li>\n<\/ul>\n<p>In addition to workflow actions, you can also create your own conditions for SharePoint Designer. A custom workflow condition is implemented as a static method that evaluates a condition and returns a Boolean value representing the result of evaluation. The example of implementation with a source code can be found in the following article: <a href=\"http:\/\/joelblogs.co.uk\/2011\/10\/29\/sharepoint-2010-audience-membership-workflow-activity-condition-for-designer-workflows\/\" rel=\"nofollow\">SharePoint 2010 Audience Membership Workflow Activity Condition for Designer Workflows<\/a><\/p>\n<p>In general, it should be noted that despite it seems quite simple, the process of SharePoint development is very complicated, time consuming and fraught with difficulties, which can be hardly predicted. But if you can\u2019t do without a custom code in your workflow, there\u2019s one more way to cut development time.<\/p>\n<p><a href=\"\/Products\/HarePointWorkflowExtensions\/Default.aspx\"><b>HarePoint Workflow Extensions<\/b><\/a> product contains \u201cExecute Custom Code\u201d workflow action that allows running the code on C# or VB.NET directly from the workflow without using Visual Studio.<\/p>\n<p><img decoding=\"async\" src=\"\/Pictures\/Articles\/sharepoint-custom-action.png\"><\/p>\n<p>Despite a number of shortcomings, the workflow in SharePoint 2010 is a powerful and convenient mechanism to automate not only business processes but also a large number of purely technical problems. If you are new to workflow, their study is a very good investment.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>SharePoint workflow is a very convenient way to solve automation problem without programming. However, at any step aside from common tasks such as document approval workflow, developers face insufficient functionality of workflow actions delivered with the product.<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[9],"tags":[25],"_links":{"self":[{"href":"https:\/\/www.harepoint.com\/Blog\/wp-json\/wp\/v2\/posts\/208"}],"collection":[{"href":"https:\/\/www.harepoint.com\/Blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.harepoint.com\/Blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.harepoint.com\/Blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.harepoint.com\/Blog\/wp-json\/wp\/v2\/comments?post=208"}],"version-history":[{"count":3,"href":"https:\/\/www.harepoint.com\/Blog\/wp-json\/wp\/v2\/posts\/208\/revisions"}],"predecessor-version":[{"id":1608,"href":"https:\/\/www.harepoint.com\/Blog\/wp-json\/wp\/v2\/posts\/208\/revisions\/1608"}],"wp:attachment":[{"href":"https:\/\/www.harepoint.com\/Blog\/wp-json\/wp\/v2\/media?parent=208"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.harepoint.com\/Blog\/wp-json\/wp\/v2\/categories?post=208"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.harepoint.com\/Blog\/wp-json\/wp\/v2\/tags?post=208"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}