Script will not run
Hello,
I have a VBS script I'm trying to run. Doe not run on remote PC.
Log come back
Another script log is
Please help
Answers (7)
http://www.itninja.com/blog/view/how-to-hide-running-a-batch-file-from-a-kscript-with-version-5-5
"I tried this and getting "printer connection cannot be removed. double click the printer name and make sure that the printer is connected to the network."
It sounds like the script is now running and is throwing the error, can you post the script.
It looks like there is a problem with your replacement variables. As you can see in the first log, it has replaced $(KACE_DEPENDENCY_DIR) with the correct path, but $(KACE_SYS_DIR) was not replaced. In the second log, it didn't replace either one. Try putting them in all caps, as indicated in the documenation. Also, you may want to make sure the PCs these are running on are on the latest Agent for the version of KBOX you're on. Additionally, you may also want to enclose the path to the script in quotes, in case the $(KACE_DEPENDENCY_DIR) is a folder w/ spaces or long filenames.
Comments:
-
Tried it and I'm getting this now in log:
Output Log
Running as: SYSTEM
Launched Process: cscript.exe
Activity Log
Launching program: 'C:\Windows\System32\cscript.exe' ' 'C:\ProgramData\Dell\KACE\kbots_cache\packages\kbots\345\printer_install_remove.vbs'' wait='false'
and nothing happens - Kdebiasse 10 years ago
http://www.itninja.com/blog/view/how-to-hide-running-a-batch-file-from-a-kscript-with-version-5-5
I use a vb script to call a batch and have a screen shot of the vbs call
Comments:
-
make sure you use the double qoutes for the file name - SMal.tmcc 10 years ago
tatus screen shots
Comments:
-
are these 64bit machines? - SMal.tmcc 10 years ago
-
Virtual PC running 32 bit. Main system is windows 8.1 64 bit. - Kdebiasse 10 years ago
-
try using the following with wscript vs cscript, make sure to include the " " in the file name.
Launch a program...
directory: $(KACE_DEPENDENCY_DIR)
file: "c:\windows\system32\wscript.exe"
parameters : printer_install_remove.vbs - SMal.tmcc 10 years ago
-
could you show where
Dir: C:\windows\system32
File"wscript
Paramete: $(kace_dep_Dir)\printer_install
Sorry I'm new to script writing - Kdebiasse 10 years ago
Directory DOES exist: c:\windows
Launched Process: cscript.exe
Activity Log
Checking if directory exists: c:\windows
Better picture of the log.
This is second log.
Launching program: '$(kace_sys_dir)\cscript.exe' 'C:\ProgramData\Dell\KACE\tmp\oxv7lilj\packages\kbots\345\vbscript.vbs' wait='false' - Kdebiasse 10 years ago
Output Log
Running as: pcadmin
Directory DOES exist: c:\windows
Launched Process: cscript.exe
Activity Log
Checking if directory exists: c:\windows
Launching program: '$(kace_sys_dir)\cscript.exe' 'C:\ProgramData\Dell\KACE\tmp\oxv7lilj\packages\kbots\345\vbscript.vbs' wait='false' - Kdebiasse 10 years ago
1) I see the VBS file is in the kbot folder
2) The VBS file will run if copy to desktop and open. But not through kace..
3) tried it as administrator and local user account kace account and still nothing. - Kdebiasse 10 years ago