I am attempting to write an add-in for Microsoft Word 2007. I'd like to create a Ribbon Button that when clicked, gets a FileStream for the current or active document. I would assume that is possible with the Visual Studio Tools for Office. Does anyone have any sample code that would show how to do this?
Let me know if you have any questions. Thanks
Best Answer
Try this out on the ribbon button code (for document-level add-ins):
Then use the standard example for FileStream.Read on MSDN
*Might need to prompt or force a save first, if unsaved changes exist.