WidgetAnnotation.ExportToJson
Contents
[
Hide
]ExportToJson(Stream, ExportFieldsToJsonOptions)
Exports the specified PDF form field to JSON format and writes the result to the provided stream.
public IEnumerable<FieldSerializationResult> ExportToJson(Stream stream,
ExportFieldsToJsonOptions options = null)
Parameter | Type | Description |
---|---|---|
stream | Stream | The stream to write the JSON output to. |
options | ExportFieldsToJsonOptions | Optional settings for exporting the form field to JSON. |
Return Value
A collection of FieldSerializationResult
indicating the result of the export operation for the specified form field and its child elements, if present.
Examples
Document document = new Document("PdfDoc.pdf");
FileStream fs = new FileStream("export.json", FileMode.Create, FileAccess.Write);
WidgetAnnotation annotation = document.Form[1];
annotation.ExportToJson(fs);
fs.Close();
See Also
- class FieldSerializationResult
- class ExportFieldsToJsonOptions
- class WidgetAnnotation
- namespace Aspose.Pdf.Annotations
- assembly Aspose.PDF
ExportToJson(string, ExportFieldsToJsonOptions)
Exports the specified PDF form field to JSON format and writes the result to the specified file.
public IEnumerable<FieldSerializationResult> ExportToJson(string fileName,
ExportFieldsToJsonOptions options = null)
Parameter | Type | Description |
---|---|---|
fileName | String | The name of the file to write the JSON output to. |
options | ExportFieldsToJsonOptions | Optional settings for exporting the form field to JSON. |
Return Value
A collection of FieldSerializationResult
indicating the result of the export operation for the specified form field and its child elements, if present.
Examples
Document document = new Document("PdfDoc.pdf");
string jsonPath = "export.json";
WidgetAnnotation annotation = document.Form[1];
annotation.ExportToJson(jsonPath);
See Also
- class FieldSerializationResult
- class ExportFieldsToJsonOptions
- class WidgetAnnotation
- namespace Aspose.Pdf.Annotations
- assembly Aspose.PDF