Google Onenote
Google Apps Script gives you the ability to create custom functionality within your Google documents, including Google Sheets, Google Docs, and more. With CData Connect Cloud, you get a MySQL interface for any of the 200+ sources supported by CData, including OneNote. The MySQL protocol is natively supported through the JDBC service in Google Apps Script, so by utilizing Connect Cloud, you gain access to live OneNote data within your Google documents.
. OneNote is a digital notebook that brings 3-ring binders to the digital era. Organize notes with sections and pages to separate thoughts by theme at school, home or work. Organize your notes. Connect your OneNote to hundreds of other services. Microsoft OneNote is a digital notebook that provides a single place for all of your notes and information — everything you need to remember and manage in your life at home, at work, or at school.
This article shows how to create a virtual database for OneNote in Connect Cloud and provides sample scripting for processing OneNote data in a Google Spreadsheet.
Our script only reads data from a specified table, but you can easily extend the script to incorporate update functionality.
Create a Virtual MySQL Database for OneNote Data
- Share OneNote notes to Google Drive, Google's cloud environment for Gmail, Google Docs, Google+, and more. Depending on your mobile device, you should see this as an option under Share.
- This app used to work fine on Chromebooks as a Chrome extension and via direct Web access. After the last ChromeOS update and the latest OneNote app update, OneNote Online no longer works. It hangs trying to configure access. Or it loads the OneDrive directory but does not open the exiting notes.
CData Connect Cloud uses a straightforward, point-and-click interface to connect to data sources and generate APIs.
- Login to Connect Cloud and click Databases.
- Select 'OneNote' from Available Data Sources.
- Enter the necessary authentication properties to connect to OneNote.
OneNote uses the OAuth authentication standard. To authenticate using OAuth, you will need to create an app to obtain the OAuthClientId, OAuthClientSecret, and CallbackURL connection properties. See the Help documentation for more information.
- Click Test Database.
- Click Privileges -> Add and add the new user (or an existing user) with the appropriate permissions.
With the virtual database created, you are ready to connect to OneNote data from any MySQL client.
Connect to OneNote Data with Apps Script
Google Onenote Templates
At this point, you should have configured a virtual database for OneNote in Connect Cloud. All that is left now is to use Google Apps Script to access Connect Cloud and work with your OneNote data in Google Sheets.
In this section, you will create a script (with a menu option to call the script) to populate a spreadsheet with OneNote data. St cleaner license key free. We have created a sample script and explained the different parts. You can view the raw script at the end of the article.
1. Create an Empty Script
To create a script for your Google Sheet, click Tools Script editor from the Google Sheets menu:
2. Declare Class Variables
Create a handful of class variables to be available for any functions created in the script.
3. Add a Menu Option
This function adds a menu option to your Google Sheet, allowing you to use the UI to call your function.
4. Write a Helper Function
This function is used to find the first empty row in a spreadsheet.
Google Onenote Class Notebook
5. Write a Function to Write OneNote Data to a Spreadsheet
Google Onenote Online
The function below writes the OneNote data, using the Google Apps Script JDBC functionality to connect to Connect Cloud, SELECT data, and populate a spreadsheet. When the script is run, two input boxes will appear:
The first one asks the user to input the name of a sheet to hold the data (if the spreadsheet does not exist, the function creates it).
The second asks the user to input the name of a OneNote table to read. If an invalid table is chosen, an error message appears and the function is exited.
Note, while the function is designed for use as a menu option, you can extend it for use as a spreadsheet formula.
Google Onenote Download
When the function is completed, you have a spreadsheet populated with your OneNote data, and you can now leverage all of the calculating, graphing, and charting functionality of Google Sheets anywhere you have access to the Internet.