EnterpriseOne Javascript Error Causing Errors In Internet Explorer
We recently went live with Employee Self-Service. In doing so, we no longer send employees their direct deposit pay stub. Over the last few days we were notified that some employees were unable to view the paycheck details.
We began troubleshooting the issue with looking at the usually culprits:
- Browser used (Firefox doesn?t work with EnterpriseOne Tools Release 8.97)
- Browser security settings (EnterpriseOne & IE7)
- Browser add-ons/plug-ins/extensions
However, nothing seemed suspect.
So, I put on the Web Developer Hat (don?t tell Charlie) and started troubleshooting. I found that there was a Javascript error in Internet Explorer. I tracked down the offending file an commented out the code.
The Javascript file that I changed was /js/JDEDTA.js.
The specific line that was causing the problem was line 344. I commented out the whole thing because who needs ?typeahead? functionality in Employee Self-Service?
[sourcecode]
340: this.saveAutoCompleteData = function(){
341: //Hack to make typeahead work in IE
342: /*if(document.all){
343: var formToPost = document.forms[this.formName];
344: window.external.AutoCompleteSaveForm(formToPost);
345: }else if (!this.isSafari){
346: var formToPost = document.forms[this.formName];
347: if (formToPost)
348: {
349: var action = formToPost.action;
350: formToPost.action = “javascript:void(0)”;
351: formToPost.submit();
352: formToPost.action = action;
353: }
354: }*/
355: }
[/sourcecode]
Try changing line 344 to include the correct variable – formToPost is the name of the form and it not the form itself. Try using
window.external.AutoCompleteSaveFrom(this);