as requested by ipswitch support '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' '''''''''''''''''''''''''''''''''''''''''''''''''''''''' Patrick Moss - Technical Support Group - Assistant Systems Administrator CyberLink, Inc.R - Featuring SurfPure Filtered Internet Access http://support.cyberlink.com (888)Plug-in2 (219)235-1400 mailto:[EMAIL PROTECTED] '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' '''''''''''''''''''''''''''''''''''''''''''''''''''''''' -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Patrick Moss - CyberLink Technical Support Group Sent: Friday, August 11, 2000 8:49 AM To: [EMAIL PROTECTED] Subject: RE: [IMail Forum] Mailbox size... MailBoxSize.txt : This File Checks For mailbox size and uses Imail1.exe to mail the user a warning message. Change the extention to vbs and edit the constants at the top any questions e-mail me @ [EMAIL PROTECTED] The attachment that I send is a screenshot as to how to change the get messages from server options in NS and OE. The text file should be changed to meet your need as well I'll send a copy of ours. Also we set each domain up with it's own directory so the email address is extracted from the path to the users folder. To test - remove the (') from the email variable in the last function and change it to your e-mail address. Hope you can use this - just thought I would try to help. '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' ''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' Patrick Moss - Technical Support Group - Assistant Systems Administrator CyberLink, Inc.R - Featuring SurfPure Filtered Internet Access http://support.cyberlink.com [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]> (888)Plug-in2 (219)235-1400 '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' ''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Zul J Sent: Friday, August 11, 2000 5:48 AM To: [EMAIL PROTECTED] Subject: [IMail Forum] Mailbox size... Hi all, I hope somebody can help me with this, is there any way that I can notify the users via email that their email almost or already exceeded the size limit.. Thanks... -Zul Please visit http://www.ipswitch.com/support/mailing-lists.html to be removed from this list. An Archive of this list is available at: http://www.mail-archive.com/imail_forum%40list.ipswitch.com/
This is Any Auto-Generated Message ------------------------------------------------------------------- We have noticed that your account is near the maximum size of 10MB. When the size reaches the Maximum all mail going to the address will be bounced back to the sender with an error message attached. To remedy this there a few different approaches: 1. Goto http://mail.cyberlink.com and clear your sent items folder and delete messages that you no longer need. 2. Set your e-mail program to not leave messages on the server. A. In Outlook Express: Remove the Check next to "Leave a copy of messages on the server" - See OE.jpg Attached B. In Netscape Communicator: Remove the check next to: "Leave messages on server" - See NS.jpg Attached ''''''''''''''''''''''''''''''''''''' You can also use the other options associated with the program that you use. In order to provide uninterrupted mail service we are providing this message. Please make the necessary changes. Any questions feel free to call the office and a tech support technician can help you, the numbers are listed below. '''''''''''''''''''''''''''''''''''''''''''''''''''''''''' Technical Support Group - Assistant Systems Administrator CyberLink, Inc.® - Featuring SurfPure Filtered Internet Access http://support.cyberlink.com [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]> (888)Plug-in2 (219)235-1400 '''''''''''''''''''''''''''''''''''''''''''''''''''''''
'' Created by Patrick Moss to check Mailbox size and automatically e-mail users with solutions '' Also e-mails a log to the administrator mailbox with the Activity summary '' For an added bonus the file makes sure that the virus Files have been applied ''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' Const ForReading = 1, ForWriting = 2, ForAppending = 8 Const MaxSize = 8.5 ' In MB Const ImailDomainsFolder = "d:\Imail\Domains\" Const Imail1exePath = "d:\IMAIL\" Const LogDir = "d:\imail\mailboxsizeutilities" Const strFrom = "[EMAIL PROTECTED]" Const strSubject = "Attention Mailbox Size Getting Dangerously High" ' This is path to a textfile with the actual message Const strText = "d:\imail\mailboxsizeutilities\MailGettingFull.txt" Const strAttachment = "d:\imail\mailboxsizeutilities\Mail.zip" ''''''''''''''''End User Config Set oShell = WScript.CreateObject("WScript.Shell") createFile() folderlist(ImailDomainsFolder) wscript.echo "all done" Sub filemanip(fldr) Dim filelocate,f4,f5,sf2,fso,intSize Set fso = Wscript.CreateObject("Scripting.FileSystemObject") set f4 = fso.GetFolder(fldr) set sf2 = f4.SubFolders For Each f5 in sf2 intSize = f5.size 'Convert to MegaBytes (MB) '1KB=1024bytes '1MB=1,048,576bytes or 1,000KB intSize = Round(intSize/1048576,2) If intSize > MaxSize Then response = writeTextLine(f5.path,intsize) Else End If Next set f4 = NOTHING Set sf2 = Nothing Set fso = Nothing end Sub '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' Sub folderlist(folderspec) On Error Resume Next dim f,f1,sf, fso Set fso = Wscript.CreateObject("Scripting.FileSystemObject") set f = fso.GetFolder(folderspec) set sf = f.SubFolders For Each f1 in sf findusersfldr(f1.path) Next Set F = NOTHING Set sf = NOTHING set fso = NOTHING end Sub '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' Sub findusersfldr(folderspec) Dim f3,f2,sf1,fso Set fso = Wscript.CreateObject("Scripting.FileSystemObject") set f2 = fso.GetFolder(folderspec) set sf1 = f2.SubFolders For Each f3 in sf1 If LCase(f3.name) ="users" Then filemanip(f3) End If Next Set F3 = NOTHING set sf1 = NOTHING set fso = nothing End Sub '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' Function writeTextLine(folder,filesize) Dim fso, ts,arrString,email arrString = split(folder,"\") email = arrString(5) & "@" & arrString(3) Set fso = CreateObject("Scripting.FileSystemObject") Set ts = fso.OpenTextFile( LogDir & "\scriptlog" & replace(DAte,"/","-") & ".log", ForAppending, True) ts.WriteLine email & vbTab & VBtab & filesize set ts = NOTHING set fso = nothing response = SendNotification(email,filesize) End Function ''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' Sub createFile() Dim FSO,TS 'Wscript.echo "d:\scriptlog" & replace(DAte,"/","-") & ".log" Set fso = CreateObject("Scripting.FileSystemObject") Set ts = fso.CreateTextFile(LogDir & "\scriptlog" & replace(DAte,"/","-") & ".log",true) set ts = NOTHING set fso = nothing End Sub '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' Function SendNotification(email,Size) Dim strCommand email = "[EMAIL PROTECTED]" strCommand = Imail1exePath & "imail1 -t """ strCommand = strCommand & email strCommand = strCommand & """ -u """ & strFrom strCommand = strCommand & """ -s """ & strSubject strCommand = strCommand & """ -f """ & strText strCommand = strCommand & """ -a """ & strAttachment 'wscript.echo strCommand oShell.Run strCommand, 1, False End Function