Click to See Complete Forum and Search --> : Trapped in Shell !!


suhaib
January 13th, 2003, 09:44 PM
Hi Guys

I was just trying my hands at WScript.Shell, and below is my program. But, it just doesn't seem to work. Could someone tell me why :(

Dim WSHShell
Set WSHShell = CreateObject("WScript.Shell")
cmmd = "<any DOS command>"
WSHShell.Run cmmd


Thanks

Suhaib

columbus2003
January 14th, 2003, 02:39 AM
You are on the right way.
cmmd = "<any DOS command>"

Check your command. Test it in Start menu > Run .

If you want to run internal commands such as dir, You need to use as "cmd dir" for NT-base or "command dir" for Win9x