C cstangor Member Licensed User Longtime User Mar 1, 2014 #1 Hello, I'm having trouble with the shell command: Code: Copy Dim shl As Shell Log (File.Exists("C:\users\n\skydrive\", "wordpad.exe")) shl.Initialize("shl", "wordpad.exe", Null) shl.WorkingDirectory = "C:\users\n\skydrive\" shl.Run(10000) 'set a timeout of 10 seconds produces: Error: org.apache.commons.exec.ExecuteException: Execution failed (Exit value: -559038737. Caused by java.io.IOException: Cannot run program "wordpad.exe" (in directory "C:\users\n\skydrive"): CreateProcess error=2, The system cannot find the file specified) This seems to happen no matter what file is called for, although the files do exist (see line 2 of code which produces true). Thanks in advance
Hello, I'm having trouble with the shell command: Code: Copy Dim shl As Shell Log (File.Exists("C:\users\n\skydrive\", "wordpad.exe")) shl.Initialize("shl", "wordpad.exe", Null) shl.WorkingDirectory = "C:\users\n\skydrive\" shl.Run(10000) 'set a timeout of 10 seconds produces: Error: org.apache.commons.exec.ExecuteException: Execution failed (Exit value: -559038737. Caused by java.io.IOException: Cannot run program "wordpad.exe" (in directory "C:\users\n\skydrive"): CreateProcess error=2, The system cannot find the file specified) This seems to happen no matter what file is called for, although the files do exist (see line 2 of code which produces true). Thanks in advance
stevel05 Expert Licensed User Longtime User Mar 1, 2014 #2 Have you tried: Code: Copy Dim shl As Shell Log (File.Exists("C:\users\n\skydrive\", "wordpad.exe")) shl.Initialize("shl", "C:\users\n\skydrive\wordpad.exe", Null) shl.WorkingDirectory = "C:\users\n\skydrive\" shl.Run(10000) 'set a timeout of 10 seconds Upvote 0
Have you tried: Code: Copy Dim shl As Shell Log (File.Exists("C:\users\n\skydrive\", "wordpad.exe")) shl.Initialize("shl", "C:\users\n\skydrive\wordpad.exe", Null) shl.WorkingDirectory = "C:\users\n\skydrive\" shl.Run(10000) 'set a timeout of 10 seconds
C cstangor Member Licensed User Longtime User Mar 1, 2014 #3 stevel05 said: Have you tried: Code: Copy Dim shl As Shell Log (File.Exists("C:\users\n\skydrive\", "wordpad.exe")) shl.Initialize("shl", "C:\users\n\skydrive\wordpad.exe", Null) shl.WorkingDirectory = "C:\users\n\skydrive\" shl.Run(10000) 'set a timeout of 10 seconds Click to expand... Thanks Steve! - you are awesome! Upvote 0
stevel05 said: Have you tried: Code: Copy Dim shl As Shell Log (File.Exists("C:\users\n\skydrive\", "wordpad.exe")) shl.Initialize("shl", "C:\users\n\skydrive\wordpad.exe", Null) shl.WorkingDirectory = "C:\users\n\skydrive\" shl.Run(10000) 'set a timeout of 10 seconds Click to expand... Thanks Steve! - you are awesome!