Class ReportBuilderOptions

Class ReportBuilderOptions

Namespace: Aspose.Words.LowCode
Assembly: Aspose.Words.dll (25.12.0)

Represents options for the LINQ Reporting Engine functionality.

public class ReportBuilderOptions

Inheritance

object ReportBuilderOptions

Inherited Members

object.GetType() , object.MemberwiseClone() , object.ToString() , object.Equals(object?) , object.Equals(object?, object?) , object.ReferenceEquals(object?, object?) , object.GetHashCode()

Examples

Shows how to populate document with data.

public void BuildReportData()
                                                    {
                                                        // There is a several ways to populate document with data:
                                                        string doc = MyDir + "Reporting engine template - If greedy.docx";

                                                        AsposeData obj = new AsposeData { List = new List<string> { "abc" } };

                                                        ReportBuilder.BuildReport(doc, ArtifactsDir + "LowCode.BuildReportWithObject.1.docx", obj);
                                                        ReportBuilder.BuildReport(doc, ArtifactsDir + "LowCode.BuildReportWithObject.2.docx", obj, new ReportBuilderOptions() { Options = ReportBuildOptions.AllowMissingMembers });
                                                        ReportBuilder.BuildReport(doc, ArtifactsDir + "LowCode.BuildReportWithObject.3.docx", SaveFormat.Docx, obj);
                                                        ReportBuilder.BuildReport(doc, ArtifactsDir + "LowCode.BuildReportWithObject.4.docx", SaveFormat.Docx, obj, new ReportBuilderOptions() { Options = ReportBuildOptions.AllowMissingMembers });
                                                    }

                                                    public class AsposeData
                                                    {
                                                        public List<string> List { get; set; }
                                                    }

Constructors

ReportBuilderOptions()

public ReportBuilderOptions()

Properties

KnownTypes

Gets an unordered set (i.e. a collection of unique items) containing System.Type objects which fully or partially qualified names can be used within report templates processed by this engine instance to invoke the corresponding types’ static members, perform type casts, etc.

public KnownTypeSet KnownTypes { get; }

Property Value

KnownTypeSet

MissingMemberMessage

Gets or sets a string value printed instead of a template expression that represents a plain reference to a missing member of an object. The default value is an empty string.

public string MissingMemberMessage { get; set; }

Property Value

string

Remarks

The property should be used in conjunction with the Aspose.Words.Reporting.ReportBuildOptions.AllowMissingMembers option. Otherwise, an exception is thrown when a missing member of an object is encountered.

The property affects only printing of a template expression representing a plain reference to a missing object member. For example, printing of a binary operator, one of which operands references a missing object member, is not affected.

The value of this property cannot be set to null.

Options

Gets or sets a set of flags controlling behavior of this Aspose.Words.Reporting.ReportingEngine instance while building a report.

public ReportBuildOptions Options { get; set; }

Property Value

ReportBuildOptions

Examples

Shows how to populate document with data.

public void BuildReportData()
                                                    {
                                                        // There is a several ways to populate document with data:
                                                        string doc = MyDir + "Reporting engine template - If greedy.docx";

                                                        AsposeData obj = new AsposeData { List = new List<string> { "abc" } };

                                                        ReportBuilder.BuildReport(doc, ArtifactsDir + "LowCode.BuildReportWithObject.1.docx", obj);
                                                        ReportBuilder.BuildReport(doc, ArtifactsDir + "LowCode.BuildReportWithObject.2.docx", obj, new ReportBuilderOptions() { Options = ReportBuildOptions.AllowMissingMembers });
                                                        ReportBuilder.BuildReport(doc, ArtifactsDir + "LowCode.BuildReportWithObject.3.docx", SaveFormat.Docx, obj);
                                                        ReportBuilder.BuildReport(doc, ArtifactsDir + "LowCode.BuildReportWithObject.4.docx", SaveFormat.Docx, obj, new ReportBuilderOptions() { Options = ReportBuildOptions.AllowMissingMembers });
                                                    }

                                                    public class AsposeData
                                                    {
                                                        public List<string> List { get; set; }
                                                    }
 English