Class ExportingEventArgs
Provides information about the export event in a rich text editor.
Inherited Members
Namespace: Syncfusion.Blazor.RichTextEditor
Assembly: Syncfusion.Blazor.dll
Syntax
public class ExportingEventArgs : EventArgs
Remarks
This class extends EventArgs to include properties for configuring export requests.
It allows developers to specify headers and form data for PDF/Word export operations.
Examples
@using Syncfusion.Blazor.RichTextEditor;
<SfRichTextEditor>
<RichTextEditorEvents OnExport="OnExportHandler" />
</SfRichTextEditor>
@code {
public async Task OnExportHandler(ExportingEventArgs args) {
if (args.ExportType == "Pdf") {
args.RequestHeader = new Dictionary<string, string> { { "Authorization", "Bearer <token>" } };
}
}
}
Constructors
ExportingEventArgs()
Declaration
public ExportingEventArgs()
Properties
CustomFormData
Gets or sets the custom form data for the export request body.
Declaration
[JsonPropertyName("customFormData")]
public Dictionary<string, string>? CustomFormData { get; set; }
Property Value
| Type | Description |
|---|---|
| Dictionary<string, string> | A Dictionary<TKey, TValue> containing form data key-value pairs. Default is null. |
Remarks
Use this property to include additional metadata or authentication data in the request body.
ExportType
Gets the type of export being performed.
Declaration
public string? ExportType { get; }
Property Value
| Type | Description |
|---|---|
| string | A string representing the export type. Possible values are |
Remarks
This property specifies the export format, allowing developers to access the format type for applying specific headers or form data.
This is a read-only property set internally by the component during the export operation.
Examples
@using Syncfusion.Blazor.RichTextEditor;
<SfRichTextEditor>
<RichTextEditorEvents OnExport="OnExportHandler" />
</SfRichTextEditor>
@code {
public void OnExportHandler(ExportEventArgs args)
{
Console.WriteLine($"Exporting as: {args.ExportType}");
}
}
RequestHeader
Gets or sets the custom headers for the export request.
Declaration
[JsonPropertyName("RequestHeader")]
public Dictionary<string, string>? RequestHeader { get; set; }
Property Value
| Type | Description |
|---|---|
| Dictionary<string, string> | A Dictionary<TKey, TValue> containing header key-value pairs. Default is null. |
Remarks
Use this property to set headers like Authorization or X-Custom-Token.