Hi all i got some problems with this vbs script
set shApp = CreateObject("shell.application")
currentPath = CreateObject("Scripting.FileSystemObject").GetAbsolutePathName(".")
set shFolder = shApp.NameSpace( currentPath )
set files = shFolder.Items()
for each files in files
if files.name <> "2" then
'msgbox("printing "&files.name)
files.InvokeVerbEx ("Print")
end if
next
This is supposed to print all the files within the scripts folder BUT it also prints the script's source code, i dont want to print the vbs script itself only the other files how do i do this ? what am i doing wrong ?? 2 is the file name of the script itself 2.vbs
Also how to close word after printing automatically ?
thanks !