Share via


Error while deploying Infopath form in workflow

When you deploy workflow as a feature and try to attach it to a document library you get this error “The Form has been closed” or a detailed error like “Value cannot be null. Parameter name: g at System.Guid..ctor(String g)”, the probable reasons could be

1. Workflow is unable to find Workflow enabled InfoPath form template.

2. The InfoPath form should be browser compatible.

3. Issue with details of receiver assembly as specified in feature.xml.

How do you troubleshoot?

Verify relative path of InfoPath form template as specified in Feature.xml for value attribute of XML tag <Property Key="RegisterForms" Value="*.xsn" />, if in case InfoPath form template is not in same folder as feature, and is in a subfolder then it should be <Property Key="RegisterForms" Value="<SUBFOLDERNAME>\*.xsn" />,

Go to Central AdminàApplication Management àManage Form Templates. Verify status of your InfoPath form template, if it is not “Ready” there is a probability that InfoPath form template is not properly deployed or there is an issue with the template. If status is “Ready” but Workflow enabled is “No”, that again indicated issue with InfoPath form. Now, how do we verify if there is an issue with form template?

Execute following command

stsadm –o verifyformtemplate – filename <FullPathOfXSN>

In case you get the message “There were 0 errors”, the above mentioned issue does not apply to you. Otherwise, Open the form in design mode and republish the form, this time please ensure that in the publishing wizard do not enter any alternate publish location, with that there should be no value against “Access path” in the last step of publishing wizard .

If after redeploying the feature you still see the same issue, verify form URN as specified in workflow.xml. The URN of an InfoPath form can be accessed in design mode through menu option FileàProperties; Id is the URN of the form.

It is important to note, unless feature is reinstalled the changed InfoPath form would not be registered.

Comments

  • Anonymous
    October 01, 2008
    I am seeing this error when I try to add a standard approval workflow to a Word document library.  It only happens on one particular web application on the farm.  any thoughts on what I should check out to resolve?

  • Anonymous
    October 01, 2008
    Please let me know what detailed error message you get, to get detailed error message change your web.config. If you still see the same message probably you need to remove your browser cache.