Home > Domino Tips > Administrator > E-mail > A 5.04 mailing list template error fix
Domino Tips:
EMAIL THIS
 TIPS & NEWSLETTERS TOPICS 

E-MAIL

A 5.04 mailing list template error fix


Gabor Katus
11.07.2000
Rating: --- (out of 5)


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


When you receive a memo from a 5.04 mailing list, the document will occur in the Draft and Inbox folders simultaneously and it opens in edit mode.

The cause is that PostedDate item is missing, and therefore the document is handled nearly as a draft.

This problem can be simply corrected. In the SendMail procedure of Process New Mail agent you have to do the following :


1. Allocate a worker variable 'dt' of Notesdatetime class
2. Actualize it by calling SetNow
3. To enhance Notes Friendliness, assign the Localtime property (or any
nonempty string, if date/time of posting is not important) to an additional
PostedDate item in the new memo.

Here's the code of corrected Sendmail. To be short the central part is missing. Additional code lines are preceeded by comments containing the denotation '***'


CODE:
Sub SendMail (subject As String, body As String, recipients As String,
whofrom As String)

' Subroutine to create email messages directly
'in the mail.box for router to deliver

'Setup sane logic
On Error Goto HandleError

'Allocate worker vars.
Dim session As NotesSession
Dim db As NotesDatabase
Dim Memobody As NotesRichTextItem
Dim object As NotesEmbeddedObject
' *** this is line is added
Dim dt As New Notesdatetime ("")

' *** the middle part of original code is cut from here ***

'Set Various memo control fields for Notes Friendliness

' *** With the next two code lines
' *** you can set PostedDate

Call dt.SetNow
memo.PostedDate = dt.Localtime

memo.Form = "Memo"
memo.From = whofrom
memo.Subject = subject
memo.MailFormat = "T"
memo.DeliveryPriority = "High"
memo.deliveryReport = "O"

Call memo.save(True,False)

Done:
On Error Goto Bail
'Misc post processing goes here
Exit Sub

HandleError:
'Aggh something fail put error on browser so it can be spotted
Dim status As String
status$ = "Error! " & Err() & " at line " & Erl() & ": " & Error()
Messagebox(status$)
Resume Done

Bail:
status$ = "Error " & Err() & " at line " & Erl() & ": " & Error()
Messagebox(status$)
Resume BailOut

BailOut:
End Sub

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.


Submit a Tip




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



RELATED CONTENT
E-mail
Secure Lotus Notes/Domino 8.x from mail to unknown recipients
Domino server setting and email policy tricks admins must know
Top 10 Lotus Notes/Domino administration tips of 2008
Can Lotus Notes/Domino and Microsoft SharePoint play nice together?
Using Formula language code to sort Lotus Notes messages by subject
LotusScript action button manages Lotus Notes mail files
Exploring Lotus Notes Domino 8.0.1 and beyond
LotusScript agent moves tagged spam email to junk mail folder
Send SMS text messages between Lotus Notes 7 and mobile devices
Update to Exchange Server 2003 Connector for Lotus Notes

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