You are currently offline, waiting for your internet to reconnect

"The form cannot run the specified query" error message in an InfoPath 2010 form after you upgrade to SharePoint Server 2010

Consider the following scenario.

  • You want to populate a field on a Microsoft InfoPath 2010 form with data from a particular view of a Microsoft SharePoint Server 2010 list. For example, you want a drop-down menu of products on backorder.
  • On the SharePoint server, this menu is a filtered view in your list of all products.
  • You create a browser-enabled InfoPath 2010 form by using Microsoft InfoPath Designer 2010 or Microsoft Office InfoPath 2007.
  • In that form, you create a data connection to an .xml file, and then you set the location to a changed URL that specifies the column and the view.
  • For this data connection, you enable Access the data from the specified location.
  • You publish the form to a Microsoft Office SharePoint Server 2007 site and the form works as expected.
After you upgrade to SharePoint Server 2010, the data connection fails, and then you receive the following error message: 
There has been an error while loading the form.

Click Try Again to attempt to load the form again. If this error persists, contact the support team for the web site.

Click Close to exit this message.
If you click Show details, you receive an error message that begins with the following text and contains a URL address:
The following location is not accessible.
The URL resembles the following address:
Additionally, the following error message is logged:
The form cannot run the specified query. The remote server returned an error: (400) Bad Request.
To work around this problem, follow these steps:
  1. Open the form template in InfoPath Designer 2010.
  2. On the Data tab, click Data Connections.
  3. Select the data connection that was listed in the error message, and then click Modify.
  4. In the URL field, append the following text to the end of the URL:
    The URL should resemble the following:
  5. Complete the Data Connection wizard, and then republish the form.
For more information about how to populate an InfoPath 2010 form with data from a SharePoint list data connection, visit the following Microsoft Developer Network (MSDN) page:

Article ID: 982245 - Last Review: 07/15/2010 07:28:00 - Revision: 3.0

  • Microsoft SharePoint Server 2010
  • Microsoft Infopath 2010
  • kbforms kbexpertiseinter kbtshoot kbsurveynew kbprb KB982245