html - I can't open an exe using Javascript -


i want open notepade.exe using html js ,i tried code not working can 1 me on this. file run.html !!!

<html>   <head>    <script>     alert("hi");     <!-- mywindow.close();   -->     var param1var = window.location.search.replace( "?", "" );     alert(param1var);     var oshell = new activexobject("shell.application");     var commandtorun = "c:\\windows\\notepad.exe";      oshell.shellexecute(commandtorun,"","","open","1");     window.close()    </script>   </head> </html> 

open internet explorer , change / enable these 2 settings

tools > internet options > security > custom level > activex controls , plug-ins > initialize , script activex controls not marked safe scripting

tools > internet options > advanced > security > allow active content run in files on computer

just in case, restart internet explorer


Comments

Popular posts from this blog

javascript - RequestAnimationFrame not working when exiting fullscreen switching space on Safari -

Python ctypes access violation with const pointer arguments -