Designer Friends,I would like to expand my current database to send out emails the the Document Author reminding them that the document has not been modified within a certain time frame.
(example 6 months to 1 year).
The Agent would scan all New Documents and Modified Documents within my Database, if that document has not been modified within a date range given, an email is sent to the Author with the Document Title & Document Link.
I reviewed this agent script, however I would like to tweak it to my needs.
This agent checks to see if a document has been modified within the last seven days. If it hasn’t, it mails a reminder memo to the document authors.
Sub Initialize
Dim session As New NotesSession
Dim db As NotesDatabase
Dim doc As NotesDocument
Dim newDoc As NotesDocument
Dim weekDateTime As NotesDateTime
Dim modifiedDateTime As NotesDateTime
Set db = session.CurrentDatabase
Set doc = session.DocumentContext
Set weekDateTime = New NotesDateTime( “Today” )
Set modifiedDateTime = New NotesDateTime( “” )
Call weekDateTime.AdjustDay( -7 ) ’ set to one week ago
modifiedDateTime.LSLocalTime = doc.LastModified
If weekDateTime.TimeDifferenceDouble( modifiedDateTime ) > 0 Then
Set newDoc = New NotesDocument( db )
newDoc.Form = "Memo"
newDoc.Subject = _
"Reminder: Please review your Document.. Its OLD!"
Call newDoc.Send( False, doc.Authors )
End If
Any suggestions on how to create a fine tuned Agent would be greatly appreciated!
End Sub
UPDATE:::
Actually - Version 6+ has the ability to create agent with predefined actions, so I have the agent made! thanks!