JsonDataSource Class
Wordize.Reporting.JsonDataSource class. Provides access to data of a JSON file or stream to be used within a report.
JsonDataSource class
Provides access to data of a JSON file or stream to be used within a report.
public class JsonDataSource
Constructors
Name | Description |
---|---|
JsonDataSource(Stream) | Creates a new data source with data from a JSON stream using default options for parsing JSON data. |
JsonDataSource(string) | Creates a new data source with data from a JSON file using default options for parsing JSON data. |
JsonDataSource(Stream, JsonDataLoadOptions) | Creates a new data source with data from a JSON stream using the specified options for parsing JSON data. |
JsonDataSource(string, JsonDataLoadOptions) | Creates a new data source with data from a JSON file using the specified options for parsing JSON data. |
Examples
Shows how to fill template with data from JSON data source loaded from file using LINQ Reporting engine.
JsonDataSource ds = new JsonDataSource(MyDir + "ReportingData.json", new JsonDataLoadOptions() { AlwaysGenerateRootObject = true });
ReportBuilder.BuildReport(MyDir + "ReportingTemplateForeach.docx", ArtifactsDir + "ReportingForeachJsonDataSource.docx", ds);
See Also
- namespace Wordize.Reporting
- assembly Wordize