Tutorial

Getting Started with Macros

Macro Editor

User Interface

Menus and Toolbar

Editing Macro Statements

Expression Editor

Macro Debugging

How To

Using variables

Finding and modifying objects

Creating new page content

Asking for user input

Storing persistent data

Using binary data

Sorting objects

Macro menus

Bulleted and numbered lists

Sample Macros

Concepts

Expressions

Objects

Properties

Variables

Data Types

Arrays

Functions

Literals

Operators

Comments

Last updated on: March 19, 2023
Also available as a single HTML file

Onetastic Macro Documentation > Page Objects > EmbeddedFile

EmbeddedFile Object

Description

Represents an embedded file attachment in a OneNote page.

Hierarchical Structure

EmbeddedFile objects can be found under following objects: Paragraph Page

Creating EmbeddedFile Objects

EmbeddedFile objects can be inserted directly under following objects: Outline Cell Page

Properties

Name Type Access Description
data Binary read-write The binary data for this EmbeddedFile.
fileName String read-write File name of this EmbeddedFile. This can only be set on newly inserted embedded files.
height Numeric read-only The height of this EmbeddedFile in points.
lastModifiedTime DateTime read-write The date and time of last modification on this EmbeddedFile.
objectId String read-write The unique identifier of this EmbeddedFile.
selection Selection read-write Whether this EmbeddedFile is fully or partially selected or not.
tags Array<Tag> read-only List of tags associated with this EmbeddedFile.
type ObjectType read-only Type of this object. Always has the value of "EmbeddedFile".
width Numeric read-only The width of this EmbeddedFile in points.
x Numeric read-write The horizontal position of this EmbeddedFile on the page in points.
y Numeric read-write The vertical position of this EmbeddedFile on the page in points.
z Numeric read-write The z-order of this EmbeddedFile on the page. Objects with higher z-order will show up in front of objects with lower z-orders.

Deprecated Properties

Following properties are deprecated. Do not use these in new macros. See descriptions below on what to use instead.

Name Type Access Description
tagCompleted Bool read-write Whether the first tag associated with this EmbeddedFile is completed (checked) or not. This property is deprecated. Use tags property instead.
tagCompletionDate DateTime read-write The date and time of completion of the first tag associated with this EmbeddedFile. This property is deprecated. Use tags property instead.
tagCreationDate DateTime read-write The date and time of creation of the first tag associated with this EmbeddedFile. This property is deprecated. Use tags property instead.
tagDisabled Bool read-write Whether the first tag associated with this EmbeddedFile is disabled (dimmed) or not. This property is deprecated. Use tags property instead.
tagFontColor Color read-only The font color for the first tag associated with this EmbeddedFile for tags that use formatting instead of a symbol. This property is deprecated. Use tags property instead.
tagHighlightColor Color read-only The highlight color for the first tag associated with this EmbeddedFile for tags that use formatting instead of a symbol. This property is deprecated. Use tags property instead.
tagName String read-only The name of the first tag associated with this EmbeddedFile. This property is deprecated. Use tags property instead.
tagSymbol Numeric read-only The symbol used for the first tag associated with this EmbeddedFile. This property is deprecated. Use tags property instead.
tagType Numeric read-only The type of the first tag associated with this EmbeddedFile. This property is deprecated. Use tags property instead.

Reference

Statements

For

ForEach

If

Else If

Else

Switch

Case

Default

While

Expression

Comment

Break

Continue

Return

Hierarchy Objects

NotebookRoot

Notebook

SectionGroup

Section

Page

Page Objects

Title

Outline

Table

Column

Row

Cell

Paragraph

Text

Image

EmbeddedFile

Tag

Other Objects

DialogBox

MacroMenu

Window

Functions

Array Functions

Color Functions

Data Store Functions

Date/Time Functions

Dialog Box Functions

Macro Execution Functions

Macro Menu Functions

Object Functions

String Functions

Window Functions