我有一个视图,顶部有一个名为Delete
我想从视图中删除所有选定的文档;为此,我使用了:
Dim session As New NotesSession
Dim workspace As New NotesUIWorkspace
Dim database As NotesDatabase
Dim documentCollection As NotesDocumentCollection
Set database=session.CurrentDatabase
Set documentCollection=database.UnprocessedDocuments
If documentCollection.Count=0 Then
Msgbox "No documents selected ",,"warning"
Else
userChoice=Msgbox ("Delete" & Cstr(documentCollection.Count) & " documents?",64+100, _
"Confirm...")
If userChoice=6 Then
Call documentCollection.RemoveAll(True)
Call workspace.ViewRefresh
End if
但是,如果我只想删除一些文档(从所有选定的文档中。从视图中)可以说文档Value = YES
中Value
的文本字段在哪里?
我尝试声明:
Dim ui As NotesUIDocument
Dim doc As NotesDocument
Set doc=ui.document
但我得到消息:Object variable not set
。所以我想我必须使用 NotesDocumentCollection 来引用文档?如何?
谢谢你的时间!