?
Solved

How to write an agent that shows # of msgs over a certain date old

Posted on 2001-07-10
8
Medium Priority
?
223 Views
Last Modified: 2013-12-18
Please show me the Lotus Script for a server-side agent that :

Creates a .txt report showing....
1) MailBox .nsf name
2) Number of messages over 1 year old

I need the script to look at all mail files in the /mail directory and report on all of them.
Not too swift with Lotus Script so don't be afraid to be specific.

0
Comment
Question by:a6106a
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
8 Comments
 
LVL 1

Expert Comment

by:anuu
ID: 6270966
It is possible to write a scheduled agent using the notesDbdirectory class and the read & write statements in LS. However, this agent will take a very long time to process the files if there are too many mail files and/or if the size of the mail files are too large. I would recommend an admin tool to get this kind of information unless you need this as a part of an application...

0
 
LVL 24

Expert Comment

by:HemanthaKumar
ID: 6271631
Approach:

Create agent with following options:

Acts On:     All documents in database
Simple Action:     Send Newsletter Summary
Add Search: Date.. date created is older than 365 days

For the news letter summary you can define subject as formula like this
"Mail Log for : " + Subject

Create a special hidden view which will collect information about all the documents in the database and use this as a template for summary

Create a mail in database, and route all the mails to this database

~Hemanth

0
 
LVL 24

Expert Comment

by:HemanthaKumar
ID: 6271632
This design change should be done in the template and propogated to every database and the agent can be scheduled for your convenience.

0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
LVL 10

Expert Comment

by:zvonko
ID: 6272213
increase the points to: 300 <|;-)
0
 

Author Comment

by:a6106a
ID: 6274465
HemanthaKumar:
definately getting there...
I have done it so that I get a message with links to all of the files within the time frame.
How do I make the message not show me links to all of the documents but simply give me a total of the number of docs that fit the date range?
0
 
LVL 24

Accepted Solution

by:
HemanthaKumar earned 400 total points
ID: 6277039
Use this script instead of simple action sending news letter summary.

Dim session as New NotesSession
Dim db as NotesDatabase
Dim col as NotesDocumentCollection
Dim doc as NotesDocument
Dim rtitem as NotesRichTextItem

set db = session.CurrentDatabase
set col = db.UnprocessedDocuments
set doc = db.CreateDocument
doc.Form = "Memo"
doc.Subject = "Mail log for: " + db.Title
set rtitem = New NotesRichtextItem(doc, "Body")
call rtitem.AppendText("Number of documents that were one year old as of " & now & " are " & col.Count
Call rtitem.AddNewLine(2)
Call rtitem.AppendText("Link to the mail db: ")
Call rtitem.AppendDocLink(db, db.Title)
Call doc.Send(false)


PS: Rest of the setup remains same. Except that you will be using script instead of simple action so that you will get only the count

~Hemanth
0
 
LVL 1

Expert Comment

by:Moondancer
ID: 6857631
Question(s) below appears to have been abandoned. Your options are:
 
1. Accept a Comment As Answer (use the button next to the Expert's name).
2. Close the question if the information was not useful to you. You must tell the participants why you wish to do this, and allow for Expert response.
3. Ask Community Support to help split points between participating experts, or just comment here with details and we'll respond with the process.
4. Delete the question. Again, please comment to advise the other participants why you wish to do this.

For special handling needs, please post a zero point question in the link below and include the question QID/link(s) that it regards.
http://www.experts-exchange.com/jsp/qList.jsp?ta=commspt
 
Please click the Help Desk link on the left for Member Guidelines, Member Agreement and the Question/Answer process.  http://www.experts-exchange.com/jsp/cmtyHelpDesk.jsp

Please click you Member Profile to view your question history and keep them all current with updates as the collaboration effort continues, to track all your open and locked questions at this site.  If you are an EE Pro user, use the Power Search option to find them.

To view your open questions, please click the following link(s) and keep them all current with updates.
http://www.experts-exchange.com/questions/Q.20109585.html
http://www.experts-exchange.com/questions/Q.20113670.html
http://www.experts-exchange.com/questions/Q.20127287.html
http://www.experts-exchange.com/questions/Q.20129572.html
http://www.experts-exchange.com/questions/Q.20148730.html
http://www.experts-exchange.com/questions/Q.20152364.html
http://www.experts-exchange.com/questions/Q.20165455.html
http://www.experts-exchange.com/questions/Q.20165450.html
http://www.experts-exchange.com/questions/Q.20169417.html
http://www.experts-exchange.com/questions/Q.20170133.html


To view your locked questions, please click the following link(s) and evaluate the proposed answer.
http://www.experts-exchange.com/questions/Q.20069131.html

PLEASE DO NOT AWARD THE POINTS TO ME.  
 
------------>  EXPERTS:  Please leave any comments regarding your closing recommendations if this item remains inactive another seven (7) days.  Also, if you are interested in the cleanup effort, please click this link http://www.experts-exchange.com/jsp/qManageQuestion.jsp?ta=commspt&qid=20274643
 
Thank you everyone.
 
Moondancer
Moderator @ Experts Exchange

P.S.  For any year 2000 questions, special attention is needed to ensure the first correct response is awarded, since they are not in the comment date order, but rather in Member ID order.
0
 
LVL 5

Expert Comment

by:Netminder
ID: 6906018
Admin notified of User neglect. Force-accepted by
Netminder
CS Moderator
0

Featured Post

[Webinar] Lessons on Recovering from Petya

Skyport is working hard to help customers recover from recent attacks, like the Petya worm. This work has brought to light some important lessons. New malware attacks like this can take down your entire environment. Learn from others mistakes on how to prevent Petya like worms.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I thought it will be a good idea to make a post as it will help in case someone else faces these issues. I trust this gives an idea how each entry in Notes.ini can mean a lot for the Domino Server to be functioning properly. This article discusses t…
Lack of Storage capacity is a common problem that exists in every field of life. Here we are taking the case of Lotus Notes Emails, as we all know that we are totally depend on e-communication i.e. Emails. This article is fully dedicated to resolvin…
This is my first video review of Microsoft Bookings, I will be doing a part two with a bit more information, but wanted to get this out to you folks.
Sometimes it takes a new vantage point, apart from our everyday security practices, to truly see our Active Directory (AD) vulnerabilities. We get used to implementing the same techniques and checking the same areas for a breach. This pattern can re…
Suggested Courses
Course of the Month8 days, 12 hours left to enroll

764 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question