This will work in IE, but as for other browsers, I'm not sure. It is important to note that yes / no / cancel is not officially supported by Javascript, so you are better off using ok / cancel where possible.
<script language=javascript> /*@cc_on @*/ /*@if (@_win32 && @_jscript_version>=5) function window.confirm(str) { execScript('n = msgbox("'+str+'","4132")', "vbscript"); return(n == 6); } @end @*/ var r = confirm("Can you do it?"); alert(r); </script>
Tom Gullen Jun 24 2018-10-06T00: 00Z
source share