LINQ Outlook, OneNote and Excel
The ScipBe.Common.Office namespace contains 3 classes : ExcelProvider (LINQ to Excel), OutlookProvider (LINQ to Outlook) and OneNoteProvider (LINQ to OneNote). The ExcelProvider loads an Excel worksheet and provides column definition and row collections. The OutlookProvider is a wrapper class which provides IEnumerable collections to data of the COM interface of Outlook ( appointments, contacts, mails, tasks, ...). The OneNoteProvider provides collections of notebooks, sections and pages by manipulating the XML hierarchy tree of OneNote. All collections are IEnumerable so you can query them with LINQ.
Check out my articles where I describe the implementation of these 3 classes and how to use them. These articles also contain a lot of LINQ query examples.
- Querying Outlook and OneNote with LINQ
- Execute queries on Office data with LINQPad
- Display Outlook contact pictures in WPF application
- Querying Excel worksheets with LINQ
- Cleaning up Outlook mailboxes
Class diagrams:
Copyrights and distribution
- These components are open source (MIT License) and may be freely distributed.
- The author doesn't give a warranty for error free running of these components and he doesn't give any support.
- See source code and help file for more information about the classes, interfaces, properties, methods, events, ...
Source code and packages
- The source code can be found on GitHub: https://github.com/scipbe/ScipBe-Common-Office
- The NuGet packages are available via: https://www.nuget.org/packages/scipbe.common.office