Important Update: Archer Community Scheduled Maintenance on November 23–24 - New Community Launching Soon! Learn More..
2021-04-22 09:13 AM - edited 2021-04-22 09:15 AM
We have a "Re-enrollment" button in the workflow for re-enrolling the record. We need to show a confirm box when that button is clicked.
If user clicks OK than workflow should run as usual else it should do nothing when Cancel is clicked.
Below is the code that I am using. It does not do anything when OK or Cancel buttons are clicked.It stays on the same window.
<script type="text/javascript">
document.getElementById("master_ondemand_21").onclick = function() {myFunction()}
function myFunction() {
confirm("Test Message");
}</script>
Please help in figuring out the code after the confirm box. Thanks
2021-04-22 09:44 AM
Well, basically you're overriding the onclick function with your own function. Remove you custom object from the layout and inspect the button element and see what functions are being called for the click and add those functions to your function and put the custom object back on the layout.
Advisory Consultant
2021-04-22 09:44 AM
Well, basically you're overriding the onclick function with your own function. Remove you custom object from the layout and inspect the button element and see what functions are being called for the click and add those functions to your function and put the custom object back on the layout.
Advisory Consultant
2021-04-23 08:06 AM - edited 2021-04-23 08:06 AM
Thanks David. In the onlick event it is calling javascript:startWorkflow('Start_WF');return false;
Should i look for Start_WF in the document or something else?
Sorry I am new to this
2021-04-23 05:50 PM