37 lines
1.4 KiB
Plaintext
37 lines
1.4 KiB
Plaintext
' VB Script Document
|
|
' option explicit
|
|
|
|
' MoveOrCopy-Files_Caller
|
|
' Verschiebe Dateien nacheinander nach einem definierten Muster
|
|
|
|
' Digital Data
|
|
' Ludwig-Rinn-Straße 16
|
|
' 35452 Heuchelheim
|
|
' Tel.: 0641 / 202360
|
|
' E-Mail: info@didalog.de
|
|
|
|
' Version 1.0.0.1
|
|
' Letzte Aktualisierung: 05.08.2016
|
|
|
|
'------------------------------------------------------------------------------------------------------------------
|
|
' Run a command. Copy that script block and paste it after this one, for step by step processing.
|
|
'------------------------------------------------------------------------------------------------------------------
|
|
|
|
' Create object
|
|
Set objShell = CreateObject("Wscript.shell")
|
|
|
|
objShell.run("powershell -file D:\ScriptFiles\MoveOrCopy-Files\BatchBarcodeSeperator_Ende\MoveOrCopyFiles.ps1")
|
|
|
|
' Deallocate WScript Shell object
|
|
Set objShell = Nothing
|
|
|
|
' Connect to Windows Management Instrumentation (WMI) object using a moniker
|
|
Set objWMIService = GetObject("winmgmts:\\.\root\cimv2")
|
|
|
|
' Execute a query to monitor process deletion
|
|
Set colEvents = objWMIService.ExecNotificationQuery("Select * From __InstanceDeletionEvent " _
|
|
& "Within 1 Where TargetInstance ISA 'Win32_Process' And TargetInstance.Name = 'powershell.exe'")
|
|
|
|
' Wait for process deletion event
|
|
Set objEvent = colEvents.NextEvent
|
|
'------------------------------------------------------------------------------------------------------------------ |