You may receive this error when trying to publish an InfoPath Form in SharePoint 2010:
“The form cannot be rendered. This may be due to a misconfiguration of the Microsoft SharePoint Server State Service. For more information, contact your server administrator.”
You need to install the ‘State Service’. Open the PowerShell for SharePoint, Run the below cmd-lets:
1. Create Session State service application:
$serviceApp = New-SPStateServiceApplication -Name "State Service"
2. Create a State Service database and associate it with a service application
New-SPStateServiceDatabase -Name "SP2010_State_Service" -ServiceApplication $serviceApp
3. Create a State Service Application Proxy and associate it with the service application
New-SPStateServiceApplicationProxy -Name "State Service" -ServiceApplication $serviceApp -DefaultProxyGroup
Other settings to verify:
- Verify that the State Service Service Application is enabled: Go to “Application Management” >> “Manage service applications”, Check whether the “State Service” is enabled.
- Verify that your web application is associated with the State Service Service Application: In “Central Administration”, Go to “Application Management” and select the “Configure service application associations” in “Service Applications” section.