Active desktop help

Dubbin1

I Like Cheese
#1
I just built a new computer and I am tring to get my active desktop to work on it. I created one on my old computer and had no problems. On this computer I cant get any programs to launch. I can get files and such to open like explorer, my computer,control panel and my D drive. Im sure I have the .vbs files done right and I have created new shortcuts in the windows folder by using the file new shortcut. I have also tried putting the path to the program in the .vbs with no luck. I am using ntfs files system and am doing everything the same way as I did on my old computer.

Here is what the vbs looks like

Dim oShell
Set oShell = WScript.CreateObject ("WScript.shell")
oShell.run "C:\Program Files\Winamp\winamp.exe"
Set oShell = Nothing

or

Dim oShell
Set oShell = WScript.CreateObject ("WScript.shell")
oShell.run "winamp"
Set oShell = Nothing

When I try the first one I get this


When I try the second one nothing happens at all.
 
M

madmax1345

Guest
#4
This may be a dumb question but is your shortcut named the same as what is in your .vbs file.

Example:
.vbs file:

Dim oShell
Set oShell = WScript.CreateObject ("WScript.shell")
oShell.run "winamp"
Set oShell = Nothing


So your short cut should be named "winamp" without quotes.
 

Lighter

. . . . . . . . .
#5
HTML header script:

<script>
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;
}
}
</script>


vbscript

Dim oShell
Set oShell = WScript.CreateObject ("WScript.shell")
oShell.run "winamp"
Set oShell = Nothing


Right?

Are you're editing your VBscript in notepad or similar program? I ask because a lot of programs insert hidden characters like carriage returns.

Try running the script I've attached (shortcut and vbscript included). If it works, it will launch Windows Media Player. If it doesn't, there's some other issue which may be the problem.
 

Dubbin1

I Like Cheese
#6
My script was the same as yours but I tried it anyway. Still no luck. Like I said I have done an active desktop before so I do know how to do it but I just cant figure out why this isnt working on this computer. I have even tried your script and mine with my old computer sitting here and it works just fine. :huh:
 

Dubbin1

I Like Cheese
#7
I think I am starting to find what the probelm is. I believe it is the space in "program files" that is giving me the problem. I started to notice that programs that are not in a file with a space will work. Now how can I fix this space problem.
 

j79zlr

Glaanies script monkey
Political User
#8
I'm not 100% on this, but you could try the old DOS naming scheme,

Dim oShell
Set oShell = WScript.CreateObject ("WScript.shell")
oShell.run "C:\Progra~1\Winamp\winamp.exe"
Set oShell = Nothing
 

Dubbin1

I Like Cheese
#9
Thats it j79zlr
Now if I just new the old DOS naming scheme I would be set :(

Lets say I want to do wmp the path is
c:\program files\windows media player\wmplayer.exe
How would that look in the DOS scheme?


EDIT: I think I got it "C:\PROGRA~1\WINDOW~3\WMPLAYER.EXE" :)
 
M

mupp

Guest
#10
Yep, I also have to use the DOS naming method for ALL of my shortcuts...I woulda told you how but it looks like I've been beaten to it ;)
Happy Active-Desktopping
 

Dubbin1

I Like Cheese
#13
I guess I got lucky on the one short file line and was having troubles with the rest so a buddy of mine made me a small program that converts the long file name to the short :) Everything works great now. Im gonna try the %20 to see if that works too.

Edit: Nope the %20 dont work
 
A

Angel333

Guest
#14
Why do you use the 'old' Method?
Look at my HP (see Sig)
This method never made problems...
 

Members online

No members online now.

Latest posts

Latest profile posts

Perris Calderon wrote on Electronic Punk's profile.
Ep, glad to see you come back and tidy up...did want to ask a one day favor, I want to enhance my resume , was hoping you could make me administrator for a day, if so, take me right off since I won't be here to do anything, and don't know the slightest about the board, but it would be nice putting "served administrator osnn", if can do, THANKS

Been running around Quora lately, luv it there https://tinyurl.com/ycpxl
Electronic Punk wrote on Perris Calderon's profile.
All good still mate?
Hello, is there anybody in there? Just nod if you can hear me ...
Xie
What a long strange trip it's been. =)

Forum statistics

Threads
61,971
Messages
673,299
Members
89,016
Latest member
Poseeut