Skip to content

Instantly share code, notes, and snippets.

@aspose-com-gists
Last active September 2, 2021 10:05
Show Gist options
  • Save aspose-com-gists/fcb444dbca0a7596b3b59050dd522468 to your computer and use it in GitHub Desktop.
Save aspose-com-gists/fcb444dbca0a7596b3b59050dd522468 to your computer and use it in GitHub Desktop.
Convert or Export OneNote File .one to Word Document DOCX or DOC
// Initialize an instance of MemoryStream class.
MemoryStream memoryStream = new MemoryStream();
// Load the OneNote .one file using Document class.
Aspose.Note.Document oneFile = new Aspose.Note.Document("Aspose.one");
// Export the .one file as PDF
oneFile.Save(memoryStream, Aspose.Note.SaveFormat.Pdf);
// Load the file using Aspose.PDF Document class.
Document file = new Document(memoryStream);
// Convert the OneNote .one file as Word DOCX document.
file.Save("SaveOutput.docx" , SaveFormat.DocX);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment