Wordize for .NET è una soluzione professionale per l'automazione dei report e la generazione programmatica di documenti ODT. La classe ReportBuilder fornisce agli sviluppatori C# la capacità di creare report ODT utilizzando template e sintassi LINQ, il che aiuta ad accelerare i processi di business intelligence, implementare contenuto ODT dinamico nei flussi di lavoro documentali automatizzati.
Funzionalità:Testa le capacità di generazione programmatica di report ODT nella demo interattiva online presentata in questa pagina. Per questo, carica un template del documento, file di dati (JSON, XML o CSV), esegui l'operazione e scarica il documento ODT generato per verifica. Il frammento di codice C# fornito è completamente pronto per l'uso nel tuo progetto .NET.
using Wordize.Reporting;
var dataSource = new JsonDataSource("data.json");
ReportBuilder.BuildReport("Input.odt", "Output.odt", dataSource, "");
using Wordize.Reporting;
var dataSource = new JsonDataSource("data.json");
ReportBuilder.BuildReport("Input.odt", "Output.odt", dataSource, "");
using Wordize.Reporting;
using Wordize.Saving;
var dataSource = new JsonDataSource("data.json");
var imageStreams = ReportBuilder.BuildReportToImages("Input.odt",
new ImageSaveOptions(SaveFormat.Odt), new[] { dataSource }, new[] { "" });
foreach (var (stream, page) in imageStreams.Select((s, i) => (s, i)))
{
using var _ = stream;
stream.Position = 0;
using var file = File.Create($"Output_{page + 1}.odt");
stream.CopyTo(file);
}
using Wordize.Reporting;
var dataSource = new XmlDataSource("data.xml");
ReportBuilder.BuildReport("Input.odt", "Output.odt", dataSource, "");
using Wordize.Reporting;
var dataSource = new XmlDataSource("data.xml");
ReportBuilder.BuildReport("Input.odt", "Output.odt", dataSource, "");
using Wordize.Reporting;
using Wordize.Saving;
var dataSource = new XmlDataSource("data.xml");
var imageStreams = ReportBuilder.BuildReportToImages("Input.odt",
new ImageSaveOptions(SaveFormat.Odt), new[] { dataSource }, new[] { "" });
foreach (var (stream, page) in imageStreams.Select((s, i) => (s, i)))
{
using var _ = stream;
stream.Position = 0;
using var file = File.Create($"Output_{page + 1}.odt");
stream.CopyTo(file);
}
using Wordize.Reporting;
var dataSource = new CsvDataSource("data.csv", new CsvDataLoadOptions() { HasHeaders = true });
ReportBuilder.BuildReport("Input.odt", "Output.odt", dataSource, "");
using Wordize.Reporting;
var dataSource = new CsvDataSource("data.csv", new CsvDataLoadOptions() { HasHeaders = true });
ReportBuilder.BuildReport("Input.odt", "Output.odt", dataSource, "");
using Wordize.Reporting;
using Wordize.Saving;
var dataSource = new CsvDataSource("data.csv", new CsvDataLoadOptions() { HasHeaders = true });
var imageStreams = ReportBuilder.BuildReportToImages("Input.odt",
new ImageSaveOptions(SaveFormat.Odt), new[] { dataSource }, new[] { "" });
foreach (var (stream, page) in imageStreams.Select((s, i) => (s, i)))
{
using var _ = stream;
stream.Position = 0;
using var file = File.Create($"Output_{page + 1}.odt");
stream.CopyTo(file);
}