Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium


invoking the exe on click of submit button

Posted on 2003-03-13
Medium Priority
Last Modified: 2010-04-09
i want to invoke the .exe application on click of the submit button.
i am adding the below code in my java script code,

 var tempFile = "sample.exe"
 var WshShell = new ActiveXObject("WScript.Shell");

the exe is getting invoked but the html file is opening before
running the exe. how can i avoid the opening of the html file.
Question by:edsrajesh
  • 2
  • 2

Expert Comment

ID: 8126928
One of the possible way to delay the opening of the html is by using a intentional loop which make ur execution delayed a bit.

a sample code for incoorporating delay functionality.
function wait(delay){
function pauseforalert(delay){
alert("Ok "+delay/1000+" seconds have elapsed");
// -->
<a href="javascript:void()" onClick="wait(1000);">click here and wait 1 sec</a><BR>
<a href="javascript:wait(2000)">click here and wait 2 secs</a><BR>

LVL 63

Accepted Solution

Zvonko earned 400 total points
ID: 8126989
You can avoid opening by using <input type=button> instead of <input type=submit>

Like this:
<input type=button value=ExecMyApp onClick="doExecMyApp()">

LVL 53

Expert Comment

ID: 8820533
This question has been classified abandoned. I will make a recommendation to the
moderators on its resolution in a week or two. I appreciate any comments
that would help me to make a recommendation.

Unless it is clear to me that the question has been answered I will recommend delete.  It is possible that a Grade less than A will be given if no expert makes a case for an A grade. It is assumed that any participant not responding to this request is no longer interested in its final disposition.

If the user does not know how to close the question, the options are here:


LVL 53

Expert Comment

ID: 9012678
It is time to clean this abandoned question up.

I am putting it on a clean up list for CS.

points to Zvonko


If anyone participating in the Q disagrees with the recommendation,
please leave a comment for the mods.


LVL 63

Expert Comment

ID: 9106305
Thanks Cd& and Mod.

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Find out what you should include to make the best professional email signature for your organization.
Finding original email is quite difficult due to their duplicates. From this article, you will come to know why multiple duplicates of same emails appear and how to delete duplicate emails from Outlook securely and instantly while vital emails remai…
The viewer will learn the benefit of using external CSS files and the relationship between class and ID selectors. Create your external css file by saving it as style.css then set up your style tags: (CODE) Reference the nav tag and set your prop…
Learn how to create flexible layouts using relative units in CSS.  New relative units added in CSS3 include vw(viewports width), vh(viewports height), vmin(minimum of viewports height and width), and vmax (maximum of viewports height and width).
Suggested Courses

572 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question