Submit Button error - Data Connection failing
      

I am the form designer and am currently testing a new form I have created, however there is an error with my submit button which Saves the form to SharePoint, I receive the following error message:

InfoPath cannot submit the form.
An error occurred while the form was being submitted.
The form cannot be submitted to the following location: http://servername/siteA/siteB/siteC/FormLibrary/FormName.xml
The file: http://servername/siteA/siteB/siteC/FormLibrary/FormName.xml" is checked out for editing by DOMAIN\MyUserName.
The operation completed successfully.

The form is not checked out to me, or open by anybody else, also check out functionality is not forced on this SharePoint library.

On searching forums I have read about using friendly server names and I am using the server's name in the URL, i.e. http://servername instead of the alias http://intranet - this had solved the problem in other forms, but not this one.

Looking closely at the rules on my submit button, the following actions occur:

  • 1st rule checks the selection of certain fields, if the conditions are right it will set the values of 3 different fields.
  • The 2nd rule saves to SharePoint using a data connection (please note this data connection works fine on different submit buttons in different views). The second rule also closes the form.

To test where the error occurs I added a series of actions to display messages, and the problem is definitely on the data connection rule.

The data connection is to save to a Sharepoint library, using a field called "filename" as the file name. The data connection allows overwrites. The file name is set the first time a file is saved (it has a condition which checks a field which gets set upon any save event - if this field is set to 0 filename gets set and this field gets set to 1 - because this field is now equal to 1, the filename field will nwever get set again).

I have 2 views on the form, one named phase 1, the other named phase 2. When the custom submit button is pressed on the phase 1 view, my data connection works, but on the save 2 view, the exact same data connection fails with the error message above.

I am using Windows 7, InfoPath 2010, SharePoint 2010, InfoPath filler form).

In Windows XP, for a different user, the error messaeg is a little different, and the form does actually save:

InfoPath cannot submit the form
An error occurred while the form was being submitted
The form cannot be submitted to the following location: http://servername/siteA/siteB/siteC/FormLibrary/FormName.xml
The file is in use by another application or user.

As I said the form does actually save its changes but still throws up this error message which will be very confusing to end users.

I've exhausted all avenues that I know of to find the cause of the error messages and I'm at a loss, please help!

Thanks,

Ben

     
February 12th, 2013 12:02pm

I am also running into the same issue.  I have an Info Path form that gets filled out by a student, then goes to the program admin for review.  She clicks review and gets the same error above that the form is checked out by her.  I cannot get this to dissappear and am having no issues on other forms.

This is the first form I am using Sharepoint Designer workflow on to direct the form on each approval to the next user who has to approve it. 

Help!!!!!

Free Windows Admin Tool Kit Click here and download it now
May 29th, 2013 8:13pm

Did you have any trouble publishing the form to that location?

Is this a browser form or client form?

May 29th, 2013 10:35pm

bgvball14. I found that the error was down to the friendly name / server name issue. I have made sure that everything uses the friendly name e.g. http://intranet instead of the servername e.g. http://servername. I made sure the data connection and all options in the publishing wizard are set to the friendly name. There were still some forms that didn't work though - this was because when trying to fix this problem I had switched several times between using the friendly /server names and some forms were looking for the template with the server name (these didn't work), other forms looked for the friendly name (these did work).

What I did was open my form library in windows explorer view and then drag each form into Notepad so I could see the source code. On the top two lines I could see the reference to the template and in some cases the template weas referenced using the server aname, which I changed to the friendly name and this worked. I did have to check every form in the library. Basically, everything should reference the friendly name (e.g. http://intranet.

Ben

Free Windows Admin Tool Kit Click here and download it now
May 30th, 2013 7:23am

My form is a browser Form.  If I open the form in the library itself and save it, it saves.  But when the form is opened from the email that is sent, it does not. 

I noticed that the URL attached to the email is another server name instead of the sharepoint server.  it opens the form, but will not allow anyone to save, giving them the message that the form is checkedout to themselves.

I have tried to make the URL hardcoded but have not had any luck with getting this to work.


  • Edited by bgvball14 Thursday, May 30, 2013 3:19 PM
May 30th, 2013 2:58pm

Thanks Ben...I will check this.  I did notice on the emails coming out that instead of pointing to the https://my.portal.com it was pointing to http://servername.com

I will try opening the forms and to see the code and see if I can correct anything in it. 

Why did Sharepoint decide to change how the links are stored, it's very frustrating to say the least!!!

Free Windows Admin Tool Kit Click here and download it now
May 30th, 2013 3:02pm

This sounds similar to the problem I was having. What fixed it for me was opening the form in Notepad (navigate to the SharePoint library, go to Open With WIndows Explorer and then drag a form into Notepad. You'll see the source code. Very near the top you should see a line of code with either: href="http://servername/ (then the URL path) or href="http://friendlyname/ (then the URL path). If yours says the server name or the wrong server name, change it to the host name e.g. http://intranet - whatever the end user sees when accessing SharePoint.
May 30th, 2013 3:06pm

I found it very frustrating as well - everything needs to point to https://my.portal.com including everything in the Publishing wizard of your InfoPath form and the data connection. It's hard to say how SharePoint will change it automatically, I know I got myself into a bit of a mess in playing around with the server / friendly names, but so far after running the fix above (on every form that pointed to the wrong location) I haven't had any problems - fingers crossed!
Free Windows Admin Tool Kit Click here and download it now
May 30th, 2013 3:10pm

I checked one of the forms in Notepad and it's pointing to the correct https://my.portal.com address.

It's the link that comes in the email that changes the URL to the http://acdtservername.com

Any ideas??

May 30th, 2013 3:29pm

Am new with this forum and I got same issue...is this topic resolve? How? thanks a lot.
Free Windows Admin Tool Kit Click here and download it now
March 25th, 2015 1:02am

Am new with this forum and I got same issue...is this topic resolve? How? thanks a lot.

This is the error we've got but for selected username only...

"The InfoPath cannot submit the form.

An error occurred while form was being submitted.

The form cannot be submitted to the following location: (library address/filename)

The file "(library address/filename)" is check out for editing i:o#.w|domain\username

The operation completed successfully. "

March 25th, 2015 1:20am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics