I had seen this error before when the form was launched with a “Source” parameter specified after the XML file name. If this parameter exists and points to an invalid URL, you can see the error. However, in my case, it was happening even when the user was just clicking on the XML filename in the library (thus no parameters). So much for that theory.
NOTE: All the “close form” actions were done with Rules - I had no code in the form (Domain level security) and I wasn’t using the default ribbon.
Several internet searches suggested a few other things that I tried and didn’t work:
- If the form is closed with an Action rule, make sure the “Don’t run remaining rules if the condition of this rule is met” checkbox is checked at the end of the rule
- In the Submit options, click on the “Advanced>>” button and check the value of the “After submit” field - this should be “Close the form”
- Try republishing the form to a new form library - this didn’t have any effect
- I cut out all the data connections (leaving only the Submit) and extra views - still got the error
- Go to the Form options under “Versioning” and manually increase the “Version number”
So I called Microsoft and they found the solution. Normally when you copy and paste a control, the new control is assigned a new ID number (look at the Control Properties under the “General” tab to see this). This insures that each button control on the form has a unique ID. Well, at some point during development, two of my buttons were assigned the same ID. Believe it or not, this is what was causing my “this form has been closed” errors. I simply assigned unique ID values to the duplicate controls, republished the form and the error went away. Problem solved!
Hopefully this will help others experiencing the same issue.
Originally posted on the Project Leadership blog at http://www.projectleadership.net/blogs_details.php?id=2622 - the original post is no longer available.