0

I need help on writing code to create a bookmarklet in firefox and chrome.

After clicking on bookmarklet it has to run a batch file/powershell file pointed to it.

i wrote a code as below:

javascript:(function(){var wshShell = new ActiveXObject("WScript.Shell"); 
wshShell.Run("F:\App\bin\CCC.bat")})();

but it throws an error as below:

ActiveXObject` is not defined

Suncatcher
  • 10,355
  • 10
  • 52
  • 90
Mpl
  • 1
  • Might this helps? [Run a bat file from javascript](https://stackoverflow.com/questions/42985964/run-a-bat-file-from-javascript) – Patrick Oct 19 '19 at 09:49
  • This article says .. we cannot use that from browser bookmark let – Mpl Oct 19 '19 at 15:11
  • Please help on how to allow ActiveXObject via browser. – Mpl Oct 20 '19 at 03:11
  • Go this Page : [Link](https://stackoverflow.com/questions/1605946/how-to-enable-activex-in-chrome) –  Oct 20 '19 at 16:48

0 Answers0