Dim session As New NotesSession
Dim db As NotesDatabase
Dim outline As NotesOutline
Dim entryA As NotesOutlineEntry
Dim entryB As NotesOutlineEntry
Dim v As NotesView
Dim emptyDB As NotesDatabase
Set db = session.CurrentDatabase
Set v = db.GetView("By Category")
Set outline = db.GetOutline("products")
Set entryA = outline.GetFirst()
Set entryB = outline.getChild(entryA)
Call entryB.SetNoteLink(emptyDB,v)
Call outline.save()