createViewNav (NotesView - JavaScript™)
Creates a view navigator for all entries in a view.
Defined in
NotesViewSyntax
createViewNav() : NotesViewNavigator
createViewNav(cacheSize:int) : NotesViewNavigator
Parameter | Description |
---|---|
cacheSize |
The size of the navigator cache in view entries. Legal values are 0 (no cache) through 128 (default). Applies only to remote (IIOP) operations. |
Return value | Description |
---|---|
NotesViewNavigator |
The new view navigator. |
Usage
The navigator contains all entries even if the view is filtered for a full-text search.An empty view results in an empty navigator. All navigation methods return null.
The cache enhances performance for iterative processing of entries using the navigation methods that do not take a parameter.
Examples
This button gets all the entries in a view.var v:NotesView = database.getView("main");
var value:string = null;
var nav:NotesViewNavigator = v.createViewNav();
var entry:NotesViewEntry = nav.getFirst();
while (entry != null) {
requestScope.status += "\n" +
entry.getColumnValues().elementAt(0);
var tmpentry = nav.getNext();
entry.recycle();
entry = tmpentry;
}