How can I open network folder for XUL? for my Firefox toolbar, it can access drives like C:, not network paths like //Development…with the code: file.initWithPath("\\DEVELOPMENT2");
Full code:
var file = Components.classes["@mozilla.org/file/local;1"]
.createInstance(Components.interfaces.nsILocalFile);
file.initWithPath("\\\DEVELOPMENT2"); //---> this is not working
//file.initWithPath("Y:"); ---> this is working
file.reveal();
var process = Components.classes["@mozilla.org/process/util;1"].createInstance(Components.interfaces.nsIProcess);
process.init(file);
var args = [];
process.run(false, args, args.length);
//end
I can see two issues:
"\\\\DEVELOPMENT2"rather than"\\\DEVELOPMENT2".