subtract (NotesDocumentCollection - JavaScript)

Removes from a document collection specified documents.

Defined in

NotesDocumentCollection

Syntax

subtract(noteid:string) : void

subtract(noteid:int) : void

subtract(documents:NotesBase) : void

Parameter Description
noteid Note ID of a document.
documents An object of type NotesDocument, NotesDocumentCollectionNotesDocumentCollection (JavaScript), NotesViewEntry, or NotesViewEntryCollection. View entries must point to documents.

Usage

The document or documents being applied by this method must be in the same database as the original collection. Otherwise, this method returns the error "the specified note or notes do not exist in the database" or, if a note ID was passed to the method that matches a note ID in the original collection's database, the method uses the unintended document.

On successful completion of this method, the original document collection contains only the documents it contained prior to the call not specified by the input argument.