It is possible to include additional information about the document. This metadata is stored in the document and can be viewed in a word processor by inspecting the document properties.
WordDocument.Create(GenerateFilePath(), document =>
{
document.Metadata(new DocumentMetadata
{
Title = "Invoice",
Subject = "Invoice for services",
Keywords = "invoice, services, payment",
CreationDate = DateTimeOffset.Now,
});
document.Section(section =>
{
section.Paragraph("Your invoice content");
});
});
| Property | Description |
|---|---|
| Title | Represents the main heading or name of the document, often displayed as a prominent identifier or label in document metadata. |
| Description | |
| Subject | Provides a brief description or main topic related to the document content. |
| Creator | Specifies the individual or entity responsible for creating the document. |
| CreationDate | Represents the date and time when the document was created. This property is used to specify the creation timestamp. |
| Keywords | Defines a collection of terms or phrases that describe the document's content or purpose, improving categorization and searchability. The value should be a string containing words delimited with a comma. |
| Company | Name of the company associated with the document. |
| Manger | Name of of manager/supervisor associated with the document. |