In January 2004, Chris Pratley wrote about "OneNote genesis". His article ended by this sentence: "…I can see how this might become addictive."
Yes, as many people who know OneNote often use the word, "addictive" is a correct adjective for OneNote.
What makes it addictive is probably the fact that it is a medium for 'not-yet-documented' ideas. In the same time, it offers a good and simple hierarchical storage that helps organize those ideas for future documentation.
One great thing is that OneNote exposes its objects and methods for developers through an API for extending its features. There are many feature-rich add-ins for OneNote, which can fit your needs in several areas.
In my case, I needed a sort of 'periscope' to explore my own notes. A tool that can let me see my notes ordered by creation or last update dates, mark and retrieve some of them as favorite items, have a quick preview of a note, locate the section's file folder, search notes' titles and/or content… etc.
Using the API, I could write a 'OneNote Explorer'… a tool I started writing in 2010, enriching it with new features from time to time.
OneNote API
OneNote API is xml-based. A set of methods in the Application Interface let you get information about opened notebooks and their structures (section groups, sections, pages… etc.) in xml format.
Understanding OneNote xsd schema is thus essential.
OneNote XSD overview: main objects
OneNote Page definition
Application overview
Application view model classes:
A static class (OneNoteHelpers) exposes several methods to communicate with OneNote API and create / update the view model objects as required:
Summary of methods exposed by the helper static class:
Features
- View selected section pages. Search titles, sort the datagrid, add page to favorites, open page in OneNote, html preview
- View all notebook pages. Search titles, sort the datagrid, add page to favorites, open page in OneNote, html preview
- Search selected notebooks
- Manage favorites: delete, preview, open in OneNote…
Page preview note
The application's Preview button displays the html content of the selected page. As OneNote API can return the page xml content, an xslt style sheet (with templates per each element type of the xsd definition) allows a simple and quick preview.
The simple page's xml tree
The page xml code
<?xml version="1.0" encoding="utf-8"?> <one:Page xmlns:one="http://schemas.microsoft.com/office/onenote/2013/onenote" ID="{138E40BA-13BB-4D24-A78C-D92E4E23D574}{1}{E1949424590587215702781963951539196781170461}" name="Sample page title" dateTime="2018-04-20T18:53:38.000Z" lastModifiedTime="2018-04-20T19:00:30.000Z" pageLevel="1" isCurrentlyViewed="true" selected="partial" lang="en-US"> <!-- ***************** quick styles ***************************** --> <one:QuickStyleDef index="0" name="PageTitle" fontColor="automatic" highlightColor="automatic" font="Calibri Light" fontSize="20.0" spaceBefore="0.0" spaceAfter="0.0" /> <one:QuickStyleDef index="1" name="p" fontColor="automatic" highlightColor="automatic" font="Calibri" fontSize="12.0" spaceBefore="0.0" spaceAfter="0.0" /> <!-- ********** page settings ********** --> <one:PageSettings RTL="false" color="automatic"> <one:PageSize> <one:Automatic /> </one:PageSize> <one:RuleLines visible="false" /> </one:PageSettings> <!-- ********** title ********** --> <one:Title selected="partial" lang="en-US"> <one:OE author="taoffi" authorInitials="T.N." lastModifiedBy="taoffi" lastModifiedByInitials="T.N." creationTime="2018-04-20T18:53:46.000Z" lastModifiedTime="2018-04-20T18:53:46.000Z" objectID="{9DB0692F-3758-49BC-8E87-F040F40599C2}{15}{B0}" alignment="left" quickStyleIndex="0" selected="partial"> <one:T><![CDATA[Sample page title]]></one:T> <one:T selected="all"><![CDATA[]]></one:T> </one:OE> </one:Title> <!-- ********** page content (main <div>) ********** --> <one:Outline author="taoffi" authorInitials="T.N." lastModifiedBy="taoffi" lastModifiedByInitials="T.N." lastModifiedTime="2018-04-20T19:00:28.000Z" objectID="{9DB0692F-3758-49BC-8E87-F040F40599C2}{30}{B0}"> <one:Position x="36.0" y="86.4000015258789" z="0" /> <one:Size width="123.9317169189453" height="14.64842319488525" /> <one:OEChildren> <!-- ********** paragra^ph ********** --> <one:OE creationTime="2018-04-20T18:53:47.000Z" lastModifiedTime="2018-04-20T18:53:52.000Z" objectID="{9DB0692F-3758-49BC-8E87-F040F40599C2}{33}{B0}" alignment="left" quickStyleIndex="1"> <!-- ********** paragraph text ********** --> <one:T><![CDATA[Sample page text]]></one:T> </one:OE> </one:OEChildren> </one:Outline> </one:Page>
|
OneNote 2010 vs. 2013 and above
There are some compatibility issues between OneNote API for 2010 version and 2013 and above. More changes have been introduced in 365 version.
The downloadable binaries here are for OneNote 2013 and 2016 desktop.
You may download the binaries Here!