I've published an InfoPath form, through the administrator route, to a document library. I can click new form on the document library and have my custom form load up in the browser. When the filled form is saved back to the list it fires off a workflow. The workflow creates a task for another user to go into the form and complete the missing fields (if there are any.)
The key here is that the partially filled form saved to the library needs to be the very same form opened in the first task. The link field of the task is automatically filled with the url to the list item, which is the xml for the partially filled form. The link is identical to that when you mouse over the item back in the document library but when it's clicked from the task it try's to open the form inside InfoPath itself and not inside the browser. So that's one problem with the link field that SharePoint automatically populates when you create a task.
Ideally I would want to associate the partially filled form with the task itself. I've done this before in workflow with infopath forms by putting the FormURN inside workflow.xml and then specifying the TaskType on the task. However this will create up a new form based on the template. How can I get it to use the existing xml on the list item which the workflow which the task is actually running on.
Suggestions would be very much appriciated.
use the tutorial on this page and have a field on the forms ItemMetadata.xml called url and set it in the code
This is not the most elegant solution but does work well. You will need to modify the form to act as an action listener. Instead of creating tasks, send out emails containing a link to the InfoPath. When the user opens the form customize the top of form to look like a task form with a checkbox, when the form is updated fire the workflow to check if the check box is complete, if so move on the workflow on.
Change the url to go this url