Hi all,
I have the following code in my JSP app:
<a href="runApp('file://capScrAndSend.bat');" class="mainbars"> CONTACT ADMIN </a>
The batch file is present in the root directory of the web application. It does two things:
1.) runs a java class which is present in a sub-directory of the web application
2.) calls upon a vbscript which is also in a sub-directory of the web application
The Javascript code for the function runApp(), present in the <head> tag of the HTML in the JSP page is the following:
<script type="text/javascript">
function runApp(which) {
WshShell = new ActiveXObject("WScript.Shell");
WshShell.Run (which,1,false);
}
</script>
The page is in the same directory as the batch file i.e. the root directory of the web application.
I have tried running the batch file by passing a lot of kinds parameters to runApp(), including its absolute path, but I get the usual "requested resource not available" HTTP Status 404 error (represented below):
type Status report
message /GSDC5Pv3/runApp('file://capScrAndSend.bat');
description The requested resource (/GSDC5Pv3/runApp('file://capScrAndSend.bat') is not available.
I would be really grateful if someone could help me run a batch file of this kind (with a relative path to the web application) in any possible form, as I really need this functionality to be implemented.
Thanks in advance. Please do reach me if any more information is needed.
I have the following code in my JSP app:
<a href="runApp('file://capScrAndSend.bat');" class="mainbars"> CONTACT ADMIN </a>
The batch file is present in the root directory of the web application. It does two things:
1.) runs a java class which is present in a sub-directory of the web application
2.) calls upon a vbscript which is also in a sub-directory of the web application
The Javascript code for the function runApp(), present in the <head> tag of the HTML in the JSP page is the following:
<script type="text/javascript">
function runApp(which) {
WshShell = new ActiveXObject("WScript.Shell");
WshShell.Run (which,1,false);
}
</script>
The page is in the same directory as the batch file i.e. the root directory of the web application.
I have tried running the batch file by passing a lot of kinds parameters to runApp(), including its absolute path, but I get the usual "requested resource not available" HTTP Status 404 error (represented below):
type Status report
message /GSDC5Pv3/runApp('file://capScrAndSend.bat');
description The requested resource (/GSDC5Pv3/runApp('file://capScrAndSend.bat') is not available.
I would be really grateful if someone could help me run a batch file of this kind (with a relative path to the web application) in any possible form, as I really need this functionality to be implemented.
Thanks in advance. Please do reach me if any more information is needed.