Home > Domino Tips > Developer > Agent > Agent to delete VBS & EXE emails (Formula)
Domino Tips:
EMAIL THIS
 TIPS & NEWSLETTERS TOPICS 

AGENT

Agent to delete VBS & EXE emails (Formula)


Craig Wiseman
12.10.2001
Rating: -4.14- (out of 5) Hall of fame tip of the month winner


Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   


This agent, when set to fire before new mail arrives, will detect and delete emails with VBS & EXE attachments. It will also send an email to the sender, receipient, and admins.



Code

mSubject := Subject;
mFrom := From;
mSendTo := SendTo;
mBadFile := "No";

mEmailSendTo := From + " , " + SendTo;
mEmailBCC := "Administrators";
mEmailCC := "";
mEmailSubject := "REJECTED: " + mSubject;
mEmailBody := "The message with the subject '" + mSubject + "' was
rejected because it contained a VBS or EXE attachment." + @Char(13)
+@Char(0) + @Char(13) +@Char(0) +
"Our policies do not allow those types of files.";


mAttachedFileNames := @UpperCase(@Implode(@AttachmentNames; ";"));
@If(@Contains(mAttachedFileNames;".VBS")|
@Contains(mAttachedFileNames;".EXE");@Set("mBadFile"; "Yes"); "");

@If(mBadFile = "Yes";@MailSend( mEmailSendTo ; mEmailCC ; mEmailBCC ;
mEmailSubject ; mEmailBody ; "" );"");
@If(mBadFile = "Yes";@DeleteDocument;"");

Rate this Tip
To rate tips, you must be a member of SearchDomino.com.
Register now to start rating these tips. Log in if you are already a member.




Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   


RELATED CONTENT
Management/Strategy
IBM tries to woo MS users to Lotus on Linux
Achiever finalist: Service (requests) with a smile
Radicati says Exchange 2003 trumps Domino in TCO
Microsoft officially launches Exchange 2003
Lotusphere registration on par with last year
Lotus blends Domino into Workplace strategy
Exchange 2003 goes under the microscope
Keep your Domino job from heading overseas
Exclusive survey: Domino salaries stay static
Experts to Domino pros: A specialty is a must in down economy

Agent
Open documents in Lotus Notes from the Web without a UNID
Fix and update Lotus Notes documents with limited access
Verify scheduled agent status with Domino Extensible Language (DXL)
How to export data from a Lotus Notes database to a CSV file
Enable or disable scheduled agents without opening the Lotus Notes database design
Creating custom views in Lotus Notes databases
Editing fields in a Lotus Notes view with Ajax
How to automatically create a backup copy of your Domino Directory
Export Lotus Notes documents to Microsoft Word via Internet Explorer
A bevy of Notes/Domino development tips

RELATED RESOURCES
2020software.com, trial software downloads for accounting software, ERP software, CRM software and business software systems
Search Bitpipe.com for the latest white papers and business webcasts
Whatis.com, the online computer dictionary

DISCLAIMER: Our Tips Exchange is a forum for you to share technical advice and expertise with your peers and to learn from other enterprise IT professionals. TechTarget provides the infrastructure to facilitate this sharing of information. However, we cannot guarantee the accuracy or validity of the material submitted. You agree that your use of the Ask The Expert services and your reliance on any questions, answers, information or other materials received through this Web site is at your own risk.



Domino & Lotus Notes Security Solutions: Authentication, Antispam, Encryption and Antivirus
HomeTopicsITKnowledge ExchangeTipsAsk the ExpertsMultimediaWhite PapersDomino IT Downloads
About Us  |  Contact Us  |  For Advertisers  |  For Business Partners  |  Site Index  |  RSS
SEARCH 
TechTarget provides enterprise IT professionals with the information they need to perform their jobs - from developing strategy, to making cost-effective IT purchase decisions and managing their organizations' IT projects - with its network of technology-specific Web sites, events and magazines.

TechTarget Corporate Web Site  |  Media Kits  |  Reprints  |  Site Map




All Rights Reserved, Copyright 1999 - 2008, TechTarget | Read our Privacy Policy
  TechTarget - The IT Media ROI Experts