'Script to copy MyFile.txt to network share
'===============================================================
' Instantiate FileSystemObject
'===============================================================
Dim objFSO
Set objFSO = CreateObject("Scripting.FileSystemObject")
'===============================================================
' Test for existence of MyFile.txt and copy if exists
'===============================================================
If (objFSO.FileExists("C:\MyFolder\MyFile.txt ")) Then
objFSO.CopyFile "C:\MyFolder\MyFile.txt", “\\Server1\SharedFolder\MyFile.txt”
Else
WScript.Echo("Unable to locate file")
End if
'===============================================================
' Release FileSystemObject
'===============================================================
Set objFSO = Nothing
Wscript.Quit