Showing posts with label InfoPath. Show all posts
Showing posts with label InfoPath. Show all posts

Thursday, April 25, 2013

Versioning Your Published InfoPath Forms

Versioning Your Published InfoPath Forms

Infopath template has version number, you can see the number via Form Options/Versioning. Also whenever you publish the infopath form, the version number is incremented.

A good practice of designing infopath form template is to show the version number on the form. You can add a calculated value field to the bottom of the form and set its default value to

substring-before(substring-after( /processing-instruction()[local-name(.)
  = "mso-infoPathSolution"], 'solutionVersion="'), '"')

Thursday, March 14, 2013

Make a radio button in InfoPath form read only


Conditional formatting is the answer. To set the control to always be disabled do the following:
  1. Right click on your field and select Rules
  2. Create a new formatting rule and click Condition
  3. Choose The expression from the dropdown 
  4. type true() or 1 in the text field (this tells InfoPath to always apply this formatting)
  5. Check the Disable this control checkbox.
  6. Click OK

Tuesday, December 18, 2012

Controls on the InfoPath Task Edit Form Not Persisting Values

The SharePoint 2010 Visual Studio workflow uses an InfoPath form as the task edit form. On the form, values of some of the controls are persisted once the task edit form is submitted, but values of some other ones are not. For instance, input a value into a textbox then submit the task edit form, then open the task edit form again, the textbox is empty, the inputted value is gone.

It turns out that the problem is caused by the column name of the task list of the workflow. Let's say there is a textbox on the InfoPath task edit form, the textbox is bound to ClientName field and default value for ClientName field is ows_ClientName via the ItemMetadata.xml file. If the workflow task list has a column named ClientName, then the value of the textbox is not persisted. For unknown reason, the workflow engine can't process ExtendedProperties["ClientName"] correctly.

Solution: The column name of the workflow task list should not be the same name from ItemMetadata.xml file, without the ows_ prefix, if the value of the control bound to the entry in ItemMetadata.xml file needs to be persisted.

Tuesday, May 8, 2012

List form can't be edited by InfoPath if the list has managed metadata column

Many people may have known about this already.

The exact error message from InfoPath is: The following fields in the SharePoint list are not supported because of their data type and will not be available in InfoPath Designer

Wednesday, July 20, 2011

"relative links" Error when verifying/uploading infopath 2010 form template

Got the following error message when trying to deploy an infopath 2010 form template with code via central administration to production:

“Relative links to Data Connection Libraries located in different SharePoint Site Collections are not supported.”


Google search found the following blog 

Relative Links” Error Message when verifying an InfoPath Form Template by Rob Finney

In summary, the url to the SharePoint site needs to be exactly the same, including upper/lower cases, in the data connection settings. So to fix, just delete the offending data connection, add it back, then convert it to data collection file, at this step, ensure the url is correct and the capitalization of each letter is exact the same as the other data connections.


Wednesday, October 6, 2010

Task failed because "sgen.exe" was not found: solution

When building an InfoPath solution with code behind, with web services references, you may run into above error message. The following link provides 2 solutions, but the first solution did not work for me, the second one did.

http://www.itjungles.com/dotnet/task-failed-because-sgen-exe-was-not-found-solution