CreateViewNavFrom (NotesView - LotusScript®)
Creates a view navigator for all entries in a view starting at a specified entry.
Defined in
Syntax
Set notesViewNavigator = notesView .CreateViewNavFrom( navigatorObject [, cacheSize& ] )
Parameters
navigatorObject
Variant. A Document or ViewEntry object representing the starting entry. If you specify Nothing, this method generates an error.
cacheSize&
Long. Optional. The size of the navigator cache in view entries. Legal values are 0 (no cache) through 128 (default).
Return value
notesViewNavigator
A NotesViewNavigator object. The new view navigator whose first entry is the specified Document or ViewEntry object; subsequent entries are all the entries in the view that follow the specified entry.
CreateViewNavFrom always returns a view navigator, but if you pass it a document that is not in the view, it will be positioned at the first entry. You can use the following to tell whether a document exists in a view or folder by looking at what it points to and seeing whether it's what you requested:
Function IsDocInView(doc As NotesDocument, view As NotesView) As Boolean
?????? Dim nav As NotesViewNavigator
?????? Set nav = view.CreateViewNavFrom(doc)
?????? Dim ent As NotesViewEntry
?????? Set ent = nav.GetFirst
?????? If Not (ent Is Nothing) Then
?????? ?????? IsDocInView = (ent.NoteID = doc.NoteID)
?????? End If
End Function
Usage
The navigator contains all entries even if the view is filtered for a full-text search.