Tutorial

Getting Started with Macros

Macro Editor

User Interface

Menus and Toolbar

Editing Macros

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: September 02, 2024
Also available as a single HTML file

Onetastic Macro Documentation > Macro Editor > Editing Macros

Editing Macros

Macro Editor allows you to inspect existing macro code and debug them. To edit macros it integrates with external code editors. Macro Editor comes with built in support for popular code editors like VSCode and NotePad++. When opening a macro, Macro Editor will offer opening the macro with an external editor of your choice:

External Editor Dialog

Once you open the macro in the external editor, you can now edit the macro and as you save the file in the external editor, Macro Editor will import and update the current macro. If you prefer a different editor than available in this list, you can click on the button to add a new external editor and use that.

You can also use the toolbar or menus of Macro Editor, or the F2 shortcut to open your macros in an external editor for editing your macros. In the Edit menu, the following options provide access to this functionality:

In the toolbar the first button is used to launch external editors or manage them:

External Editor Button

Finish Editing in External Editor

While you are editing your macro in the external editor, you can return to Macro Editor and debug your macro. Don't forget to save the macro in the external editor so that it can import the latest changes. Once you are done editing in the external editor, you can close the file and click on Finish Editing button in the toolbar or the Edit menu so that Macro Editor stops monitoring the file edited by the external editor.

Finish Editing Button

Managing External Editors

To manage all the external editors, click on Manage External Editor, either from the Edit menu or the toolbar. This will open the following dialog:

Manage External Editors Dialog

Here you can add, remove, and change the order of external editors.

Reference

Statements

Hierarchy Objects

Page Objects

Other Objects

Functions

Array Functions

Color Functions

Data Store Functions

Date/Time Functions

Dialog Box Functions

Macro Execution Functions

Macro Menu Functions

Object Functions

Special Functions

String Functions

Window Functions