I have a UIDoc that has an embedded view that displays other docs. When I open one of the docs via the embedded view, I want the UIDoc that was opened … closed and leave only the doc that was opened through the embedded view open.
How do I get the main UIDoc to close when opening a doc through the embedded view?
Subject: The solution is in the view !!
You have docA with the embedded view (view_A). So open view_A in Designer, go to ‘Queryopendocument’ and paste this code:
Dim ws as New NotesUIWorkspace
dim uidoc as NotesUIDocument
set uidoc = ws.CurrentDocument
uidoc.Close
Now every time you open a document from your embedded view (for example by doublecklicking), docA or lets say the uidoc, is closed and only the newly opened docB leaves open.
Subject: Closing UIDoc, after opening diff doc via embedded view
Try using an agent to open the document and close the current document?