I have developed an XPages application (on an XWorks Server) which works well with Firefox, Chrome and Internet Explorer 11. However, with Internet Explorer 9 I frequently get the error message "application is not responding due to a long running script" when switching between Read Mode and Edit Mode (and also when clicking on buttons which execute Dojo CSJS and SSJS). I have tried deselecting "runtime optimized JS and CSS" but the problem remains. What else can I try to resolve this problem?
The code behind the Edit Button is:
<xp:button id="button2">
<xp:this.value><![CDATA[${javascript:
applicationScope.get("actEditDocument")}]]></xp:this.value>
<xp:this.rendered><![CDATA[#{javascript:
var aLevel = getComponent("HasAuthorRights").getValue();
var hasStatusAccess = getComponent("HasStatusAccess2").getValue();
var cLevel = @If((!currentDocument.isEditable() && (hasStatusAccess == @True()
|| @IsNewDoc() == 1)),"1","0");
@If(aLevel == "1" && cLevel == "1",true,false)}]]></xp:this.rendered>
<xp:eventHandler event="onclick" submit="true"
refreshMode="partial" id="eventHandler1"
refreshId="AllJobReferencePanel" disableValidators="true"
execMode="partial">
<xp:this.action>
<xp:actionGroup>
<xp:changeDocumentMode
mode="edit">
</xp:changeDocumentMode>
</xp:actionGroup>
</xp:this.action>
<xp:this.script>
<xe:dojoFadeOut
node="AllJobReferencePanel" duration="10000">
</xe:dojoFadeOut>
</xp:this.script></xp:eventHandler>
</xp:button>
EDIT: I also added
var exCon = facesContext.getExternalContext();
var response = exCon.getResponse();
response.setHeader("X-UA-Compatible", "IE=EmulateIE7");
to the beforeRenderResponse event of each XPage