Developer Guide
This guide covers the core capabilities of Aspose.Words FOSS for .NET — the same Document Object Model used by the commercial Aspose.Words for .NET product, reduced down to a free, open-source core.
Working with Documents
using Aspose.Words;
Document doc = new Document();
DocumentBuilder builder = new DocumentBuilder(doc);
builder.Writeln("Hello, Aspose.Words FOSS!");
doc.Save("output.docx");DocumentBuilder provides high-level methods for inserting text, moving the cursor to sections, bookmarks, and tables, and applying font, paragraph, and page formatting. The full document object model is also available directly through the node tree, or by subclassing DocumentVisitor.
Supported Formats
DOCX, DOCM, DOTX, DOTM, and Flat OPC (plus its macro-enabled and template variants) are all supported for both load and save, sharing the same OOXML reader/writer. Markdown and plain text are supported for both load and save as well.
Key Classes
| Class | Namespace | Description |
|---|---|---|
Document | Aspose.Words | Root document object |
DocumentBuilder | Aspose.Words | High-level cursor-based document authoring API |
Section | Aspose.Words | A document section |
Paragraph | Aspose.Words | A paragraph of text |
Table | Aspose.Words.Tables | A table shape |
Field | Aspose.Words.Fields | Base class for document fields |
Known Limitations
The following are not part of this FOSS edition:
- Page layout and rendering: no PDF, XPS, or image export, and no printing — layout-dependent field values (such as page numbers in a TOC) evaluate to
0rather than being computed. - Additional formats: DOC, RTF, ODT, HTML, and EPUB are not read or written.
- Mail merge execution, LINQ Reporting, document comparison, and embedded-font subsetting are not included.
- Digital signatures can be verified but not created.
See each section below for the specific classes and methods available for a given capability area.
See Also
- Getting Started: Building from source and your first program
- API Reference: Class and method reference
- How-To Guides: Task-oriented how-to articles
- Aspose.Words for .NET — Enterprise Documentation