Loading |
VBScript |
JavaScript |
Powershell |
Search Options: Determine Whether a File Exists on a Remote ComputerContent of Determine Whether a File Exists on a Remote Computer.vbsMD5 Hash: D30BA65E0D561F1F29FAACCE335501E2 |
||
strComputer = "atl-fs-01"
Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root\cimv2") Set colFiles = objWMIService. _ ExecQuery("Select * From CIM_DataFile Where Name = 'C:\\Scripts\\Test.vbs'") If colFiles.Count = 0 Then Wscript.Echo "The file does not exist on the remote computer." Else Wscript.Echo "The file exists on the remote computer." End If | ||
© 2008 - 2013 Boris Toll :: Scripts available: 6.481 :: :: scriptbox.toll.at :: :: powered by www.toll.at :: |