TxtSaveOptionsBaseExportHeadersFootersMode Property

Specifies the way headers and footers are exported to the text formats. Default value is PrimaryOnly.

Namespace:  Aspose.Words.Saving
Assembly:  Aspose.Words (in Aspose.Words.dll) Version: 20.3
Syntax
public TxtExportHeadersFootersMode ExportHeadersFootersMode { get; set; }

Property Value

Type: TxtExportHeadersFootersMode
Examples
Shows how to specifies the way headers and footers are exported to plain text format.
Document doc = new Document(MyDir + "Header and footer types.docx");

// Three values are available in TxtExportHeadersFootersMode enum:
// "None" - No headers and footers are exported
// "AllAtEnd" - All headers and footers are placed after all section bodies at the very end of a document
// "PrimaryOnly" - Only primary headers and footers are exported at the beginning and end of each section (default value)
TxtSaveOptions saveOptions = new TxtSaveOptions { ExportHeadersFootersMode = txtExportHeadersFootersMode };

doc.Save(ArtifactsDir + "TxtSaveOptions.ExportHeadersFooters.txt", saveOptions);
See Also