When you are loading InfoPath form or InfoPath web part which is calling a data connection, you receive error “error occurred while trying to connect to a web service”.
Data connection Time out.
- While loading the form or InfoPath web parts, you get the error to while trying to connect to a web service.
- In the ULS logs you see the following errors
- InfoPath Forms Services Runtime – Data Connections c4nh Unexpected The following data connection (GetUserProfileByName) has exceeded the maximum configured time limit. This threshold can be configured by using the SPIPFormsService -MaxDataConnectionRoundTrip PowerShell commandlet
- Data adapter failed during OnLoad: The remote server returned an error: (500) Internal Server Error. Server was unable to process request. —> System.ServiceModel.ServiceActivationException
- DataAdapterException, Exception Message: The remote server returned an error: (500) Internal Server Error. Server was unable to process request. —> System.ServiceModel.ServiceActivationException The remote server returned an error: (500) Internal Server Error.)
- This means the InfoPath form services data connection round trip data connection time out value is exceeded. Round trip data connection time out value cannot be set through UI in the Central administration site, it has to be done using PowerShell scripts.
To increase time out value :
Set-SPInfoPathFormsService -MaxDataConnectionRoundTrip 25000
Get value of all InfoPath form services settings :
$SPInfopath| select *
Increasing time out value is always based on the business requirements and to be done with lot of caution. It might cause performance issues. To be tested in a test farm before applying on the production.
Published by: Menaka Sarkar B.