I had testing with customer and most of parts of our solution works except this.
Solved! Go to Solution.
Hi All,
I did some further research and added the workflow to my custom list that I have developed for this solution. It looks, we cannot add start options for items automatically for default SharePoint lists such as calendar, workflow tasks during my testing.
Here is my attempt to make Workflow Tasks to open in edit mode but I was unsuccessful:
Running a workflow to modify the tasks themselves might not be the best solution here. A quicker option that I found to work would be to add a code snippet to the Workflow Task List page to update the links to reference the form edit page as opposed to the form display page.
Go to your workflow task list and click the cog wheel, then 'Edit Page'
Click 'Add a Web Part'
Go to the 'Media and Content' Section and select 'Script Editor' then click 'Add'
From there, click edit snippet within the Web Part
Insert the code snippet below:
<script type="text/javascript" src="https://code.jquery.com/jquery-1.12.4.min.js"></script>
<script type="text/javascript">
$(document).ready(function()
{
$('.ms-vb a[href*="listform.aspx"]').each(function(){
var formurl = $(this).attr('href');
formurl = formurl.replace("PageType=4", "PageType=6");
$(this).attr('href', formurl);
});
});
</script>
Click 'Stop Editing' on the page and try opening your task forms. They should be directed to the edit version now!