Posted by sshenriksen
Can you put like a little link for a program on the desktop ( not icons) but more like my own stuff?
Say you have a little symbol you want as link to photoshop for instance. I keep getting something like: Filetransfer: Would you like to open the file. It can damage the PC if you do.
Something like that. Is there somewhere I missed permissions or something?
Thanks in advance. And when I am done I will post in December desktops as well
Sune
Call this function
function exec (command) {
if (document.layers && navigator.javaEnabled()) {
window._command = command;
window.oldOnError = window.onerror;
window.onerror = function (err) {
if (err.indexOf ("User didn't grant") != -1) {
alert('command execution of ' + window._command +
' disallowed by user.');
return true;
}
else return false;
}
netscape.security.PrivilegeManager.enablePrivilege
('UniversalExecAccess');
java.lang.Runtime.getRuntime().exec(command);
window.onerror = window.oldOnError;
}
else if (document.all) {
window.oldOnError = window.onerror;
window._command = command;
window.onerror = function (err) {
if (err.indexOf('utomation') != -1) {
alert('command execution of ' + window._command +
' disallowed by user.');
return true;
}
else return false;
};
var wsh = new ActiveXObject('WScript.Shell');
if (wsh)
wsh.Run(command);
window.onerror = window.oldOnError;
}
from a link passing the FULL PATH to the exe ... not a shortcut and that would work ..
mooz