How to run .exe on a Webpage

HTML ImageThere are certain scenarios where you need to run your .EXE file through HTML page. In this blog I will show you how can you achieve this task on html page by using JavaScript.

Click here to Execute your file

The above code will call a user defined function call LaunchApp() which you can see in the following code snippets.

alert ("This ActiveXObject is only available for Internet Explorer"); return; } var ws = new ActiveXObject("WScript.Shell"); ws.Exec("D:\\Software\\youfile.exe"); }

In the above JavaScript a LaunchApp() is defined which will first check for the browser if your browser is not internet explorer  then it will show you message that your browser doesn’t support the ActiveXObject and only available for InternetExplorer,If it is InternetExplorer then it will create object for WScript.Shell and will execute yourfile.exe in the D:\software location.

Source: http://codereflex.net/how-to-run-exe-on-webpage/

Comments are closed.