EmbeddedObjects (NotesDocument - JavaScript)

Read-only. The OLE/2 and OLE/1 embedded objects in a document.

Defined in

NotesDocument

Syntax

getEmbeddedObjects() : java.util.Vector

Usage

Unlike the EmbeddedObjects property in NotesRichTextItem, this property does not include file attachments, nor OLE/1 objects created in Notes® Release 3.

This property does include OLE/2 and OLE/1 objects created in Release 4 and higher. It also includes objects in the document that were originally embedded in the document's form. Such objects must have been activated, modified, and re-saved in order to be returned by this property (otherwise they remain a part of the form, not the document).

The vector is empty if the document contains no embedded objects.

Examples

This computed field displays the names of embedded objects in the document.
var doc:NotesDocument = currentDocument.getDocument();
if (doc.hasEmbedded()) {
	var eos:java.util.Vector = doc.getEmbeddedObjects();
	if (eos.isEmpty()) {
		return "Contains attachments"
	} else {
		var msg:string = "Contains embedded objects:";
		var eosi:java.util.Iterator = eos.iterator();
		while (eosi.hasNext()) {
			var eo:NotesEmbeddedObject = eosi.next();
			if (msg.endsWith(":")) {
				msg = msg + " ";
			} else {
				msg = msg + "; ";
			}
			msg = msg + eo.getName();
		}
		return msg;
	}
} else {
	return "No embedded documents"
}