C++ API for Word Document Processing
Product Page | Docs | Demos | API Reference | Examples | Blog | Search | Free Support | Temporary License
A standalone C++ class library to load, save, format & convert Microsoft Word® documents without Office Automation.
Aspose.Words for C++ is a powerful on-premise API that can be used for a great range of document processing tasks such as; working with documents, sections, tables, bookmarks, fields, form fields, DocumentBuilder, ranges, comments, content control SDT, images, styles, charts, watermarks, lists, shapes, mail merge, rendering, printing and much more.
Word File Processing Features
- Call the Document constructor without parameters to programmatically create a new blank document.
- Detect the file format and check file format compatibility.
- Convert Word Documents to other supported formats.
- Serialize a document object to fetch a byte array and vice versa.
- Supports conversion compliance with various PDF standards.
- Export fonts to HTML in
Base64
encoding.
- Save any password encrypted word document.
- Specify the OOXML specification.
- Apply a password to encrypted documents and ignore
RoutingSlip
data while saving.
- Compress all the metafiles, be it small or large.
- Enable bi-directional marks to add support for the right to left languages.
- Access the VBA Project to extend functionality.
- Read, write, or modify VBA Macros.
- Clone VBA Project or VBA Module.
Microsoft Word: DOC, DOT, DOCX, DOTX, DOTM, FlatOpc, FlatOpcMacroEnabled, FlatOpcTemplate, FlatOpcTemplateMacroEnabled, RTF, WordML
OpenDocument: ODT, OTT
Web: HTML, MHTML
Markdown: MD
Fixed Layout: PDF
Text: TXT
Microsoft Word: DocPreWord60
eBook: MOBI, CHM
Save Document As
Fixed Layout: XPS, OpenXps
PostScript: PS
Printer: PCL
eBook: EPUB
Markup: XamlFixed, HtmlFixed, XamlFlow (Beta), XamlFlowPack (Beta)
Image: SVG, TIFF, PNG, BMP, JPEG, GIF
Metafile: EMF
Get Started
Are you ready to give Aspose.Words for C++ a try? Simply execute Install-Package Aspose.Words.Cpp
from Package Manager Console in Visual Studio to fetch the NuGet package. If you already have Aspose.Words for C++ and want to upgrade the version, please execute Update-Package Aspose.Words.Cpp
to get the latest version.
Create DOCX with HelloWorld Text via C++
Try executing the following snippet to see how Aspose.Words for C++ performs in your own environment or check the GitHub Repository for other common usage scenarios.
// create a blank document.
System::SharedPtr<Document> doc = System::MakeObject<Document>();
// the DocumentBuilder class provides members to easily add content to a document.
System::SharedPtr<DocumentBuilder> builder = System::MakeObject<DocumentBuilder>(doc);
// write a new paragraph in the document with the text "Hello World!"
builder->Writeln(u"Hello World!");
// save the document.
// the format to save as is inferred from the extension of the file name.
doc->Save(u"output.docx");
Aspose.Words for C++ allows you to convert Microsoft Word® formats into bytes, EPUB, HTML, and other file formats. The following code sample displays how to convert a DOC file into an EPUB format using C++:
// load the document from disk.
System::SharedPtr<Document> doc = System::MakeObject<Document>(u"template.doc");
// Save the document in EPUB format.
doc->Save(u"output.epub");
Product Page | Docs | Demos | API Reference | Examples | Blog | Search | Free Support | Temporary License