Home > Domino Tips > True Domino Bloopers > True Domino Blooper #17: Help wanted
Domino Tips:
EMAIL THIS
 TIPS & NEWSLETTERS TOPICS 

TRUE DOMINO BLOOPERS

True Domino Blooper #17: Help wanted


Kurt Ringleben
11.21.2002
Rating: --- (out of 5)


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


This Domino architect got in a spot of trouble when the auto-responder agent he created worked a little too well. Read more to find out what happened when the head honcho ordered our hero to get a handle on his pesky agent.


My first week at my current employer, I was asked to create an "auto-responder" for our "careers" e-mail account.

The idea was to reply to any e-mail messages that were sent to this account with a "Thank you for your interest" message. I created an agent called "OppAutoReply" and set it to trigger "before new mail arrives" with the following code:

Sub Initialize 
        Dim session As New NotesSession 
        Dim db As NotesDatabase 
        Dim doc As NotesDocument 
        Dim smtp2 As NotesDocument 
        
        Set db = session.CurrentDatabase         
        Set doc = New NotesDocument( db ) 
        Set smtp2 = session.DocumentContext 
        
        Ifrom = smtp2.from(0) 
        
        doc.Form = "Memo" 
        doc.INetFrom = "opportunity@domain.com" 
        doc.SendTo = smtp2.from(0) 
        doc.Subject = "COMPANY NAME - Resume Received" 
        Set body = New NotesRichTextItem(doc, "Body" ) 
        Call body.AppendText("Thank you for your interest in pursuing employment opportunities etc...") 
        Call body.addnewline(3) 
        Call body.AppendText("Regards,") 
        Call body.addnewline(2) 
        Call body.AppendText("COMPANY Recruitment Team") 
        Call doc.Send( False ) 
        
End Sub 

Now this worked perfectly...until I get a call from the president of the company. He was wondering why I was sending him an e-mail message regarding his resume.

Apparently, the recruiter was scheduling meetings from this account (as to not "block out" his time). When a hiring manager would accept/decline the meeting, he would get the auto-response.

So, red-faced, I added an If statement to only reply to e-mails that contained an @ in the From field.

OH BUT WE'RE NOT DONE YET! Two weeks later I get a call from the recruiter that the mail database had about 700 e-mail messages in it and adds 20 more every time he hits refresh.

Apparently a job posting Web site sent an e-mail message with a bad ReplyTo address. My agent sent the auto-response; the response generated a nondel; the nondel generated an auto-response and so on and so on!

So I set the ReplyTo to "postmaster," and it's been working without a hitch for a few months now. However, I still hear about it from the president of the company every once in a while, asking me when he can sit down for that interview!

In case anyone's interested, here's the finished agent:

Sub Initialize 
        Dim session As New NotesSession 
        Dim db As NotesDatabase 
        Dim doc As NotesDocument 
        Dim smtp2 As NotesDocument 
        
        Set db = session.CurrentDatabase         
        Set doc = New NotesDocument( db ) 
        Set smtp2 = session.DocumentContext 
        
        Ifrom = smtp2.from(0) 
       
        If Instr(Ifrom,"@") Then 
                doc.Form = "Memo" 
                doc.INetFrom = "opportunity@domain.com" 
                doc.ReplyTo = "postmaster@domain.com" 
                doc.SendTo = smtp2.from(0) 
                doc.Subject = "COMPANY NAME - Resume Received" 
                Set body = New NotesRichTextItem(doc, "Body" ) 
                Call body.AppendText("Thank you for your interest in pursuing employment etc.. ") 
                Call body.addnewline(3) 
                Call body.AppendText("Regards,") 
                Call body.addnewline(2) 
                Call body.AppendText("COMPANY Recruitment Team") 
                Call doc.Send( False ) 
        End If 
End Sub
-- Christopher Toohey


Do you have your own blooper? Send it in and claim your fame.

Every story in our bloopers series comes to us directly from a SearchDomino.com administrator, developer or consultant. For obvious reasons, some contributors choose to remain anonymous.

MORE ON THIS TOPIC:

Read all SearchDomino.com's true bloopers.
View our Best Web Links on Domino/Notes administration.

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
True Domino Bloopers
True Domino Blooper #29: Agent OOPS
True Domino Blooper #28: The Super Server Upgrade
True Domino Blooper #27: Blame it on Domino
True Domino Blooper #1: The Out-Of-Office nightmare
True Domino Blooper #2: Independence Day blunder
True Domino Blooper #3: Return to sender
True Domino Blooper #4: Extended directories or bust!
True Domino Blooper #5: I'm not a Notes expert, but I play one on TV
True Domino Blooper #7: AdminP worm unleashed
True Domino Blooper #8: With vacations like this, who needs work?

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 technology professionals with the information they need to perform their jobs - from developing strategy, to making cost-effective purchase decisions and managing their organizations' technology projects - with its network of technology-specific websites, events and online magazines.

TechTarget Corporate Web Site  |  Media Kits  |  Site Map




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