StampAll fails with (soft) Deletion Stubs

Using Stampall in the NotesDocumentCollection fails when any one of the docs in counted collection represents a deletion stub. It would be great if the NotesDocCollection class could just not represent any deletion stubs ( maybe a bug ?)

Error gen’ed is “Document has been deleted .” Soft Deletions are in effect for the db.

Here is the code. Tried this with a recursive loop and same problem . Have isolated it to StampAll. You can try this in a simple discussion database as an agent working on the view.

Work around is to use a much less efficient loop without StampAll.

Any help appreciated.

Sub StampResponseDocs( doc As NotesDocument, currentstatus As String )

Dim ResColl As NotesDocumentCollection

Dim ResResColl As NotesDocumentCollection

Dim currentResponse As NotesDocument

Set ResColl = doc.Responses

Set currentResponse = ResColl.GetFirstDocument



If ResColl.Count > 0 Then

	Call ResColl.StampAll("STATUS", currentstatus )	

Else

End If

' check and stamp any R-R docs.

While Not ( currentResponse Is Nothing )

	Set ResResColl = currentResponse.Responses

	If ResResColl.Count > 0 Then

		Call ResResColl.StampAll("STATUS", currentstatus )	

	Else

	End If		

Wend

End Sub

Subject: StampAll fails with (soft) Deletion Stubs

You should be able to remove them from the collection before using StampAll. Iterate through the collection and use Call collection.DeleteDocument(doc)

where notesDocument.IsDeleted is true.