New Developer Tools are Available for Macros
Meet Macro Debugger and Object Browser
December 10, 2017
Macro Editor now allows running macros step by step under the debugger via the or buttons. This will switch the editor into the debugger mode and will display the next statement with a yellow background, activate the Object Browser with local variables and show the debugger buttons at the bottom:
Once in the debugger mode, you can step through the macro and see the local variables in the Object Browser. Following buttons appear in the debugger mode:
- Continue (F5): Continue execution until the next breakpoint
- Step Over (F10): Execute the next statement and then break
- Stop (Shift+F5): Stop debugging and go back to the editor
- Restart: Restart debugging and break at the first statement
- Toggle Breakpoint (F9): Sets or removes a breakpoint at the selected statement
Breakpoints
You can set a breakpoint on a statement using Toggle Breakpoint button or the
F9 key. This works both in the editor and in the debugger. The statements with a
breakpoint will show with a maroon background
and the debugger will stop when it hits one of the breakpoints.
Object Browser
Macro Debugger automatically displays the Object Browser on the right. Object Browser allows
browsing OneNote hierarchy under Current Page, Section, Section Group, Notebook and under all notebooks.
This way you can look into how the objects and their properties are stored in OneNote. This is also useful while editing a macro and can be activated using button. Object Browser
displays local variables currently in use in the macro under Locals section, allowing you
to see the types and values of them.
Licensing
These additional developer tools are available via Onetastic Developer License. You can find more details
here.
Demonstration
Watch the short video below to learn more about how to use these tools:
Comments