Filtering documents within a view in LotusScript straightforwardly can require quite a lot lines of code with various functions. However, by simple modular programming, you can use less functions in the code, making code more friendly and readable, thus reducing the chances to make a mistake, and increasing re-usability.
Here's the sample of straightforward code:
set view = db.GetView("myView")
Dim doc As NotesDocument
call view.Refresh()
dim name as string
dim evaluation
evaluation = evaluate("@username")
name = evaluation(0)

