Lotus Notes: Is it possible to create a view that excludes documents in all folders other than Inbox?

折月煮酒 提交于 2019-12-13 01:25:45

问题


I am aware that you can exclude certain folders - but you have to name them. I need a view to show only the documents in the inbox, that doesn't need updating everytime we create a new folder.

Any help would be greatly appreciated!

:)


回答1:


It is not possible directly. There are no formulas that would help you build a select statement to get documents that are only in the Inbox. However, you could have an agent run on a scheduled basis (maybe every 5-10 minutes) that would update documents and flag them if they are in the inbox. Your view would then just need to select documents that have that flag set.

Updated As umeli pointed out, the flag needs to be unset when documents are moved out of the Inbox. Here's a modified script:

For example:

Dim s as New NotesSession
Dim db as NotesDatabase
Dim view as NotesView
Dim doc as NotesDocument
Dim allEntriesInbox as NotesViewEntryCollection
Dim allEntriesFlagged as NotesViewEntryCollection    

Set s = New NotesSession
Set db = s.CurrentDatabase
Set view = db.GetView("($Inbox)")
Set viewFlagged = db.GetView("IsInInboxView")

Set allEntriesInbox = view.AllEntries
Set allEntriesFlagged = viewFlagged.AllEntries

allEntriesFlagged.StampAll("IsInInbox", "")
allEntriesInbox.StampAll("IsInInbox, "1")

Your view (named "IsInInboxView" in this example) should have a selection formula of IsInInbox = "1"



来源:https://stackoverflow.com/questions/24329560/lotus-notes-is-it-possible-to-create-a-view-that-excludes-documents-in-all-fold

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!