Put a good copy of virus.fwd in the root d: directory or edit the script
change extention to vbs -
-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]On Behalf Of
[EMAIL PROTECTED]
Sent: Monday, May 22, 2000 8:31 AM
To: [EMAIL PROTECTED]
Subject: RE: [IMail Forum] problem with rules.ima
> put a .fwd file in each users box with where you want the emails to go.
>
> This has been covered earlier, with someone posting a ncie utility to do
> place the .fwd files.
I missed this nice utility, is it available somewhere...?
Thanks,
Jeff
Please visit http://www.ipswitch.com/support/mailing-lists.html
to be removed from this list.
'''''''''''''''''''''''''''''''''''''''
'
Dim fso, strFile, strCommand,FileToCheck,directory, rc
Const ForReading = 1, ForWriting = 2, ForAppending = 8
' End User config
Set fso = Wscript.CreateObject("Scripting.FileSystemObject")
strFile = "d:\virus.fwd"
FileToCheck = "\virus.fwd"
RootDirectory = "d:\imail\domains"
folderlist(RootDirectory)
''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
function fileexist(filespec)
On Error Resume Next
dim msg
if (fso.FileExists(filespec)) Then
msg = 1
else
msg = 0
end if
fileexist = msg
end Function
''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
Sub folderlist(folderspec)
On Error Resume Next
dim f,f1,sf
set f = fso.GetFolder(folderspec)
set sf = f.SubFolders
For Each f1 in sf
findusersfldr(f1)
Next
end Sub
''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
Sub findusersfldr(folderspec)
Dim f3,f2,sf1
set f2 = fso.GetFolder(folderspec)
set sf1 = f2.SubFolders
For Each f3 in sf1
If LCase(f3.name) ="users" Then
filemanip(f3.path)
End If
Next
Set WshShell = WScript.CreateObject("WScript.Shell")
WshShell.Popup sf1.name & "all done",2
Set WshShell = nothing
End Sub
''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
Sub filemanip(fldr)
Dim filelocate,f4,f5,sf2
'wscript.echo filelocate
set f4 = fso.GetFolder(fldr)
set sf2 = f4.SubFolders
For Each f5 in sf2
If fileexist(f5.path & filetocheck) = 0 Then
CreateFile(f5.path & filetocheck)
Else
End If
Next
end Sub
'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
Sub CreateFile(file)
Dim TextFile
On Error Resume Next
Set TextFile = fso.GetFile(strFile)
textFile.Copy file
Set textfile = Nothing
Set FSO = Nothing
End Sub