I created a custom button on the Quote object that executes JavaScript, and everything works fine except for a critical call to HTMLElement.click(). The kickers to this problem are:
- The button works fine in Firefox and Chrome, just not in IE10
- The same code works when I run it from IE10's developer tools Console
Does anyone have any ideas why this is happening? And any workarounds?
I can reproduce the problem consistently via the following steps:
- Create and activate at least two new quote templates, e.g., "United States Standard Template" and "United Kingdom Standard Template"
- Create a custom button on the Quote object labeled "Create My PDF", which executes the following JavaScript:
document.getElementById("createpdf").click();
- Add the custom button to an applicable Quote page layout, making sure the standard Create PDF is also present
- Open IE10, and on a Quote detail page, click the Create My PDF button. Nothing happens. But if you press F12 and run the exact same JavaScript in the Console, it works as expected.