SharePoint Workflows Fail Using IE11
Early adopters of Windows 8.1 and/or Internet Explorer 11 (IE11) may notice some issues when working in their SharePoint environments. I have not fully explored the bugs and nuisances caused by IE11 but discovered a particular issue with out-of-the-box (OOTB) workflows. After saving my publishing page and clicking the submit button to fire the workflow process, I’m greeted with a critical error.
There has been a critical error while processing the form.
The error message in full: There has been a critical error while processing the form. Click Start Over to load a new copy of the form. If this error persists, contact the support team for the Web site.Click Close to exit this message.
The error details mention that the method ‘addEventListener‘ is not supported. This threw me for a loop for a good hour or so until I realized that SharePoint 2010 Master Pages by default, and best practice, include the X-UA-Compatible tag and it is set to IE8. Shame on me – because I’ve blogged about this very thing in the past. But for some reason this has always worked in IE9 and IE10 – rendering in IE8 mode and using a function that shouldn’t be available. So why does this break using IE11 all of a sudden?
Armed with this information it was just a matter of time until I found the culprit – the file: /inc/Core.js has a function: Window.AttachEventHandlers causing this error. One of the very first things this function does is check the strBrowser value, and if set to 3 it attaches an event listener. No problem, except that Microsoft determined that strBrowser 3 supports the addEventListener method – in which this case they have been proven wrong. If you are using Internet Explorer 11 and your Master Page sets the compatibility tag to IE8 you will get this error! If you set the browser mode to any other value (9, 10, edge) the problem goes away.
## The Solution
Anyone concerned with IE11 & SharePoint 2010 (2007?) compatibility and experiencing the error message regarding addEventListener has a few choices:
- Tell everyone on the (choose: internet, intranet) using IE11 to use compatibility mode (joke).
- Wait for Microsoft to fix it (not recommended, and a joke).
- Update Core.js manually in the hive (not recommended).
- Add this little bit of code to the bottom of your Master Page, just before the closing <body> tag (recommended):
Let me know if you implement this code on your site and how it works. Did it solve any other issues you were experiencing? Are there other issues with SharePoint 2007 or 2010 OOTB functionality that needs to be fixed for IE11?