OneNote PowerShell Provider by Brian Dewey

I always feel honoured to work in Office because there are so many incredible people working throughout the org.  In particular I met Brian Dewey a few months ago; Brian is a fellow PM in Office and a big OneNote fan and a very savvy geek.  What happens when you combine those traits?  Well Brian created a OneNote PowerShell Provider : )   Here is what he has to say about it:

I now use these programs all the time. And like a Reese’s Peanut Butter Cup, I wondered if these two great technologies would be even better if brought together? So I’ve tried to bring them together in the form of a OneNote PowerShell provider. This is a PowerShell extension that lets you create and manipulate OneNote notebooks, sections, and pages from PowerShell. You can use provider to do some interesting automation using OneNote.

He goes on to explain how he has a script which will email members of shared notebook that there are new edits in that notebook all with a couple hundred lines of code.  This is so easy since PowerShell does an amazing job with XML and OneNote exports XML, after reading what Brian has done I am really excited to learn more about how PowerShell works.  What is even better is that Brian is releasing the source code (so I can learn) as well as compiled versions of his provider, see here:

If you want to play with the OneNote PowerShell extension, I’m making it publicly available under the Microsoft Community License. You can find the binary files here: OneNotePowershell.msi. The source files are here:

If you install the provider, it will install several sample scripts as well, including the script I’ve been discussing here (Get-OneNoteDigest.ps1).

If you just want to read the documentation that comes with the provider and the scripts, it exists in OneNote format: OneNote PowerShell Documentation.

If you want to use PowerShell with OneNote to build useful tools, let me know. I’ll be curious to see how you use it.

This is just so cool!  Brian has binaries, source and a documentation notebook (in OneNote format to boot!).  Check it out here: OneNote PowerShell Provider.  Great work Brian!

Update on 2008-Mar-11:  I just heard from Brian that some files were moved around and you can now find the files here:

Updated on 2008-Mar-14 - With this link:

Comments (7)
  1. This looks very interesting if you are looking for a way to automate some of your OneNote 2007 activities

  2. SS says:


    Does not work consistently unfortunately. Great idea though.

  3. Simon Savva says:

    When I say it doesn’t work consistently, not entirely correct…what I mean is the PSdrive behaviour is strange, though it can be worked around by ensuring the location is specified explicitly on every command. Must ensure that set-location is not "OneNote:"

    PS C:Onenote> set-location onenote:

    PS OneNote:> dir

    Get-ChildItem : Cannot find path ‘OneNoteOneNote:’ because it does not exist.

    At line:1 char:4

    + dir <<<<

    PS OneNote:> set-location onenote:

    PS OneNote:> dir

    Get-ChildItem : Cannot find path ‘OneNoteOneNote:’ because it does not exist.

    At line:1 char:4

    + dir <<<<

    PS OneNote:> set-location "onenote:client requests"

    PS OneNote:client requests> dir

    Get-ChildItem : Cannot find path ‘OneNoteOneNote:client requests’ because it does not exist.

    At line:1 char:4

    + dir <<<<

    PS OneNote:client requests>

    Would really love if you could correct me and/or fix this, as otherwise, this provider is excellent.

  4. Simon Savva says:

    Sorry to post again, but I think I found a solution…


    Remove-PsDrive OneNote

    New-PSDrive -Name OneNote -PsProvider OneNote -Root " "

    …traversing the OneNote store works as described now…I just hope the fix hasn’t introduced any new problems 😉

  5. Yong says:

    FYI: the onenote provider does not work completely in Onenote 2010.

    So, make sure you convert your notebook to 2007.

  6. Sudeep says:


    Sounds interesting. Can I use powershell to copy the contents of an office document into onenote?

Comments are closed.

Skip to main content