EntriesProcessed (NotesCalendar - JavaScript™)
Read-only. Number of entries processed by getEntries
and readRange
operations.
Defined in
NotesCalendarSyntax
getEntriesProcessed() : int
Usage
Use this property as the third parameter to getEntries and readRange to process entries in successive operations.Examples
This button event uses getEntries to get calendar and scheduling information for the current user for today and tomorrow.var dbdir:NotesDbDirectory = session.getDbDirectory("");
var maildb:NotesDatabase = dbdir.openMailDatabase();
var cal:NotesCalendar = session.getCalendar(maildb);
var dt1:NotesDateTime = session.createDateTime("Today 08");
var dt2:NotesDateTime = session.createDateTime("Tomorrow 17");
var entries:java.util.Vector = cal.getEntries(dt1, dt2, 0, 1);
while (entries.size() > 0) {
var cale:NotesCalendarEntry = entries.firstElement();
requestScope.status = requestScope.status + cale.read() + "\n";
cale.recycle();
entries = cal.getEntries(dt1, dt2, cal.getEntriesProcessed(), 1);
}
This button event uses readRange to
get calendar and scheduling information for the current user for today
and tomorrow.
var dbdir:NotesDbDirectory = session.getDbDirectory("");
var maildb:NotesDatabase = dbdir.openMailDatabase();
var cal:NotesCalendar = session.getCalendar(maildb);
var dt1:NotesDateTime = session.createDateTime("Today 08");
var dt2:NotesDateTime = session.createDateTime("Tomorrow 17");
var entrystring:String = cal.readRange(dt1, dt2, 0, 1);
while (entrystring.length() > 0) {
requestScope.status = requestScope.status + entrystring + "\n";
entrystring = cal.readRange(dt1, dt2, cal.getEntriesProcessed(), 1);
}
LotusScript® syntax and examples
NotesCalendar.EntriesProcessed As Long
This
agent uses getEntries to get calendar and
scheduling information for the current user for today and tomorrow.Sub Initialize
Dim session As New NotesSession
Dim maildb As New NotesDatabase("", "")
Dim cal As NotesCalendar
Dim cale As NotesCalendarEntry
Dim entries As Variant
Dim dt1 As NotesDateTime
Dim dt2 As NotesDateTime
Dim db As NotesDatabase
Dim doc As NotesDocument
Dim body As NotesRichTextItem
REM Get calendar for current user
Call maildb.Openmail()
Set cal = session.getCalendar(maildb)
Set dt1 = session.createdatetime("Today 08")
Set dt2 = session.Createdatetime("Tomorrow 17")
Set db = session.CurrentDatabase
REM Create document to post results
Set doc = db.CreateDocument
doc.Form = "main"
doc.Subject = "Today and tomorrow"
Set body = doc.Createrichtextitem("body")
REM Get entries and put in body of document
entries = cal.Getentries(dt1, dt2, 0, 1)
While Not IsEmpty(entries)
Set cale = entries(0)
Call body.Appendtext(cale.Read())
Call body.Addnewline(1)
entries = cal.Getentries(dt1, dt2, cal.Entriesprocessed, 1)
Wend
Call doc.Save( True, True )
End Sub
This agent uses ReadRange to
get calendar and scheduling information for the current user for today
and tomorrow.
Sub Initialize
Dim session As New NotesSession
Dim maildb As New NotesDatabase("", "")
Dim cal As NotesCalendar
Dim entrystring As String
Dim dt1 As NotesDateTime
Dim dt2 As NotesDateTime
Dim db As NotesDatabase
Dim doc As NotesDocument
Dim body As NotesRichTextItem
REM Get calendar for current user
Call maildb.Openmail()
Set cal = session.getCalendar(maildb)
Set dt1 = session.createdatetime("Today 08")
Set dt2 = session.Createdatetime("Tomorrow 17")
Set db = session.CurrentDatabase
REM Create document to post results
Set doc = db.CreateDocument
doc.Form = "main"
doc.Subject = "Today and tomorrow"
Set body = doc.Createrichtextitem("body")
REM Get entries and put in body of document
entrystring = cal.ReadRange(dt1, dt2, 0, 1)
While entrystring <> ""
Call body.Appendtext(entrystring)
Call body.Addnewline(1)
entrystring = cal.ReadRange(dt1, dt2, cal.Entriesprocessed, 1)
Wend
Call doc.Save( True, True )
End Sub
Java™ syntax and examples
int NotesCalendar.getEntriesProcessed()
This
agent uses getEntries to get calendar and
scheduling information for the current user for today and tomorrow.import lotus.domino.*;
public class JavaAgent extends AgentBase {
public void NotesMain() {
try {
Session session = getSession();
AgentContext agentContext = session.getAgentContext();
// (Your code goes here)
DbDirectory dbdir = session.getDbDirectory("");
Database maildb = dbdir.openMailDatabase();
NotesCalendar cal = session.getCalendar(maildb);
DateTime dt1 = session.createDateTime("Today 08");
DateTime dt2 = session.createDateTime("Tomorrow 17");
// Create document to post results
Database db = agentContext.getCurrentDatabase();
Document doc = db.createDocument();
doc.appendItemValue("Form", "main");
doc.appendItemValue("subject", "Today and tomorrow");
RichTextItem body = doc.createRichTextItem("body");
// Get entries and put in body of document
java.util.Vector entries = cal.getEntries(dt1, dt2, 0, 1);
while (entries.size() > 0) {
NotesCalendarEntry cale = (NotesCalendarEntry)entries.elementAt(0);
body.appendText(cale.read());
cale.recycle();
body.addNewLine(1);
entries = cal.getEntries(dt1, dt2, cal.getEntriesProcessed(), 1);
}
doc.save(true, true);
} catch(Exception e) {
e.printStackTrace();
}
}
}
This agent uses readRange to
get calendar and scheduling information for the current user for today
and tomorrow.
import lotus.domino.*;
public class JavaAgent extends AgentBase {
public void NotesMain() {
try {
Session session = getSession();
AgentContext agentContext = session.getAgentContext();
// (Your code goes here)
DbDirectory dbdir = session.getDbDirectory("");
Database maildb = dbdir.openMailDatabase();
NotesCalendar cal = session.getCalendar(maildb);
DateTime dt1 = session.createDateTime("Today 08");
DateTime dt2 = session.createDateTime("Tomorrow 17");
// Create document to post results
Database db = agentContext.getCurrentDatabase();
Document doc = db.createDocument();
doc.appendItemValue("Form", "main");
doc.appendItemValue("subject", "Today and tomorrow");
RichTextItem body = doc.createRichTextItem("body");
// Get entries and put in body of document
String entrystring = cal.readRange(dt1, dt2, 0, 1);
while (entrystring.length() > 0) {
body.appendText(entrystring);
body.addNewLine(1);
entrystring = cal.readRange(dt1, dt2, cal.getEntriesProcessed(), 1);
}
doc.save(true, true);
} catch(Exception e) {
e.printStackTrace();
}
}
}