Javascript – get current folder of HTA

I have an old solution (not created by me ..) which works like this:

  • Double click on a HTA which is stored at the internal network
  • it calls Internet Explorer which displays a “dialogue” (the HTA)
  • I select a XML file with HTA
  • I press the button “Check” which calls a Javascript-file to check the XML
  • Report the result in HTA

Usually it works as described, but now a new user on the old PC has problems:
It does not find the JS-file.

In the HTA there is the snippet

....    
ID="objHTML"
.....
<script language="JavaScript">
var instpfad=objHTML.commandLine;
var instpfad=instpfad.substr(0,instpfad.lastIndexOf('\'));
instpfad=instpfad.replace('"',''); //allf. " am Anfang entfernen
//alert(instpfad);

Every working PC returns the path of the network-folder where the HTA and the JS are stored; just the “bad PC” returns nothing and later it displays “Cannot find c:foobar.js”

  • We checked the access of the user to the network – it’s OK
  • We checked the security settings of IE – it’s OK

Any ideas what’s wrong?