How to customize SharePoint Designer Workflow Task form in SharePoint Online? - sharepoint

I'm trying to customize layout, add javascript and change some other visuals in SharePoint Designer workflow task form. I'm using SP Online and this is related to SharePoint 2013 Workflow (not SharePoint 2010).
Previous versions generate InfoPath or ASPX forms for each task. 2013 does not. Instead it uses content types for tasks but tasks always open in edit mode using a common EditForm.aspx located in ../WorkflowTasks/EditForm.aspx
I suppose changing this form will affect all workflows on that site, which is not the goal.
Is there a way to force SPD to create a dedicated edit form for each individual workflow task? I tried to change the Edit Form attribute on a content type used with my existing tasks but it has no effect.
I can browse WorkflowTasks folder contents in SPD and each associated content type gets a respective folder. I thought SPD would put task forms in there but that's not the case.
Anyone has an idea?
How do I go about creating SPD workflow and edit the ASPX task forms?
Thank You!

Create a custom content type based on Workflow Task (SharePoint 2013) content type.
You can then select a custom content type in your task.
See https://sharepoint.stackexchange.com/questions/171646/custom-task-forms-edit-display-new-in-sharepoint-2013-online-office-365 for additional info.

Related

Sharepoint2010 custom design as WSP

I am trying to get a solution for my issue. I have a set of HTML CSS and Images, which I want to apply to my sharepoint portal as a part of branding.
My concern is I want to make my design as WSP or any other kind of solution so that it can be installed in any sharepoint 2010 portal so that the user can switch back between actual sharepoint design and this custom design.
In short I have a custom HTML design which I need to implement to any sharepoint website, this design can be turned On or Off by the administrator just using the portal/Site screens.
Thanks in advance
SharePoint branding is always a tricky job. The safest way to achieve your goal is to create a separate masterpage with your new branding. So the user can choose to apply the default branding with the default masterpage and when he wants another branding your customized masterpage can be used.
Create a new SharePoint project and add the needed css inside a mapped layouts folder. Then you can reference your own css file in the new masterpage. Watch out with changing the masterpage, because it contains a lot of placeholders which will render different parts of the page. Try to work around these placeholders and make sure the masterpage works in different scenario's (ex. that the layout isn't broken when page is in edit mode, ...)
Once you are finished with the design, the user can use it by applying it in the settings. Another option to make it easier for the enduser, is to create a control that is a switch to apply your masterpage (ex. with custom action).

Sharepoint 2010 add,edit,delete forms replace to custome visual web parts

It`s possible in sharepoint 2010, will set up a list of custom data source and then adapt new input forms from visual web parts which will replace the existing add, edit and delete forms?
if it is possible, then how?
Here is an article on MSDN that describes how to use InfoPath to customise the Display, Edit and New forms for external list data (business connectivity services).
Just like in SharePoint 2007 you can change the association of the New, Edit and Display forms using SharePoint Designer in SharePoint 2010. You can create new ASPX pages, or use InfoPath forms as per the above. These ASPX pages can contain the functionality you want directly, or host visual web parts with the right permissions.
Here is an article that describes how to change the associated forms for a list with SharePoint Designer. I would recommend creating new pages and associating the list to those rather than trying to update the existing pages. This avoids any problems if the out of the box files are updated by a service pack / hotfix etc, and also allows you to revert to the out of the box forms if needed.

Is it possible to add workflow modification programmatically?

I`m interested in adding SharePoint Workflow Modification programmatically from my workflow, without using forms.
What i'm trying to achieve - I want to add Workflow modification when user uploads new document version to document library. I have OnWorkflowItemChanged and from there i'm willing to add WF Modification.
Is this possible?
To clarify some things:
I`m writing a custom Workflow in Visual Studio.
What I want is to add items to (SPWorkflowModificationCollection) SPWorkflow.Modifications object. However there is no Add method, but the designed way to add items there is by using Workflow Modification forms.
In this case, i don't want user to use modification form, but i want to add workflow modifications (which will populate the collection AND triger OnWorkflowModified event).
I am not 100% sure what you mean by workflow modification. Do you want to modify the workflow itself from a workflow or just modify a document or item from a SharePoint Workflow?
Regardless, I'll give you the same answer to what was accepted as the answer to a similar question.
Workflow is one of the strong parts of SharePoint. Out-of-the box you or your users can build workflows using the free SharePoint Designer. Depending on your exact requirements this may be good enough.
If you need a more advanced workflow editor then you may want to consider Nintex Workflow or K2. Alternatively you can write your own workflows in Visual Studio or buy 3rd part Workflow Actions for SharePoint Designer.
I have included some useful links below:
Building workflows using SharePoint Designer
Creating workflows using Visual Studio
3rd Part Workflow actions to embed VB or C# directly into SharePoint Designer Workflows. Note that I have worked on this product so consider my recommendation biased ;-)

Cannot associate a custom SharePoint Workflow with a Content Type in SharePoint Server 2010

To preface, I am working with SharePoint Server 2010 Beta 2, Visual Studio 2010 Ultimate RC.
I have built a custom Content Type based on the Item type with a few custom site columns. I also have built a custom Sequential Workflow using Visual Studio 2010. This is a relatively simple workflow that creates a task, waits for the task to complete, sets the workflow to complete. I am able to deploy this workflow to the site collection through VS 2010 deploy (which is pretty nice, btw). The problem I have is that when I try to associate the custom Content Type with my custom workflow, that workflow is not listed in the workflow templates to choose from. There are only the OOTB SharePoint workflows to choose. The kicker is that if I create a list and associate a workflow to that list, my custom workflow is in the workflow template list. This makes sense since at the start of building a custom workflow in VS2010, one of the first questions is whether the workflow is a Site or a List workflow and I selected List. Is the issue that List workflows are not allowed to be associated with Content Types?!?
Thanks.
In your workflow's elements.xml, look for AssociationCategories and change it to ContentType like so:
<AssociationCategories>ContentType</AssociationCategories>
Big thanks to my co-worker, Yves for pointing this out :)

Accessing list data from a different site in Sharepoint Designer workflow

Does anyone know if it is possible to Lookup list data from a different site when creating a workflow with Sharepoint Designer 2007? The Define Workflow Lookup dialog only allows you to pick from lists in the current Sharepoint site you are creating the workflow in.
Ideally I'd like to be able to pick from a list in the parent site, or a site from a given URL (eg. http://myserver/mysite)
You cannot do that with OOTB activities. However you can build a custom SharePoint designer activity to do the task you need. We usually create just a call web service activity and then we call a SharePoint we service we need.
Take a look at this CodePlex project for some custom SharePoint Designer activities.
SPDActivities on CodePlex are very useful. However, if your exact requirements are not covered by any of those activies then you may want to consider embedding c# or vb.net code directly into the SharePoint Designer Workflow (Without resorting to Visual Studio).
I wrote a blog article about how to do it exactly at the following location:
http://www.muhimbi.com/blog/2009/12/embed-c-or-vb-code-directly-in.html

Resources