JellyBean: Aguirard had a better solution on a very similar question a while ago. <a href=”http://itknowledgeexchange.techtarget.com/itanswers/how-to-change-the-status-of-the-documents-by-using-scheduled-agent/”>Link</a>.
There are a few ways to do this.
the easiest is probably using a view that contains the documents you want to change the status of.
you view selection criteria would look something like this:
<b>Select Form = “Your_Form_Name” & @days(@created) > 90 & Status != “Changed”</b>
Where Status !=
This is the name of your status field and !=, not equal to, the status you propose to change it to.
This will display documents created more than 90 days ago.
Then run an agent over this view and change your status.
Your Agent code:
Dim db As New NotesDatabase( “Server Name”, “Your database.nsf” )
Dim view As NotesView
Dim doc As NotesDocument
Set view = db.GetView( “your View name” )
Set doc = view.GetFirstDocument
While Not(doc Is Nothing)
Call doc.ReplaceitemValue(“Status”, “your new Status”)
Set doc = view.GetNextDocument(doc)