How to insert Word/Excel/... printout into onenote Page. Using C# and Microsoft.Office.Interop.OneNote

Add-in Express™ Support Service
That's what is more important than anything else

How to insert Word/Excel/... printout into onenote Page. Using C# and Microsoft.Office.Interop.OneNote
 
MitchT86


Guest


Hello together,

I'm looking for a way to insert a file printout like the OneNote command "Insert FilePrintout" does.
[img]https://lh4.googleusercontent.com/proxy/UL2myiQ3EgAT3FX-FfI3bZGafmbSdcT0OipdVd6sj06LAZ9zeDsh1YdVE6YyP0bzuC5pCS3L7b3-gLOTkFAHneFTjO-GiEtkbYs3KorBODraHjTNd_t-1ueHkADHWAMC_pHSTe-X2M7RUbs=w1200-h630-p-k-no-nu[/img]

All file formats that OneNote itself supports must be supported (e.g docx, xlsx, pdf, png, bmp,...)


Thanks for your help,

Best regards,
Mitch
Posted 16 Nov, 2020 08:45:06 Top
Andrei Smolin


Add-in Express team


Posts: 18825
Joined: 2006-05-11
Hello Mitch,

That functionality is missing in the OneNote object model. With any other Office application it would be possible to invoke such a built-in button programmatically but OneNote doesn't provide the CommandBars object and I don't see a way to do this without CommandBars.ExecuteMso().


Andrei Smolin
Add-in Express Team Leader
Posted 16 Nov, 2020 09:45:40 Top