我在 wwitch .pcl 中有一个文件夹,并且写入了 .ps 文件。
我希望打印这些文件,如果找到的话,唯一的可能是 cmd LPR命令
脚本是:
set shApp = CreateObject("shell.application")
Set oShell = WScript.CreateObject ("WScript.Shell")
currentPath = "c:\printAll\"
set shFolder = shApp.NameSpace( currentPath )
set files = shFolder.Items()
for each files in files
if files.name <> "printAll" then
'msgbox("printing "&files.name)
oShell.run "cmd.exe /C LPR -S SRV00APP.N-IX.LOCAL -P HP400MFP #{shFolder}/#{files.name} "
end if
next
如何将属性作为currentPath或files.name 传递给 cmd 行命令?