WebDocumentViewerOperationLogger.BuildStarting(String, XtraReport, ReportBuildProperties) Method

Called before starting to asynchronously build a report document.

Namespace: DevExpress.XtraReports.Web.WebDocumentViewer

Assembly: DevExpress.XtraReports.v18.2.Web.dll

Declaration

public virtual Action BuildStarting(
    string reportId,
    XtraReport report,
    ReportBuildProperties buildProperties
)
Public Overridable Function BuildStarting(
    reportId As String,
    report As XtraReport,
    buildProperties As ReportBuildProperties
) As Action

Parameters

Type Name Description
String reportId

A String value, identifying the report.

XtraReport report

An XtraReport object.

ReportBuildProperties buildProperties

A ReportBuildProperties object.

Returns

Type Description
Action

A Action delegate.

If a document is already built, calling this method will not build it one more time, asynchronously.

An action returned by this method is called in a separate thread on starting asynchronous building of a report document.

The following example illustrates how to use the BuildStarting method to provide synchronous building of report documents (e.g., to enable accessing HttpContext values in the XRControl.BeforePrint event handlers of a report).

using DevExpress.XtraReports.UI;
using DevExpress.XtraReports.Web.WebDocumentViewer;
using System;
// ...

public class ViewerOperationLogger : WebDocumentViewerOperationLogger {
    public override Action BuildStarting(string reportId, XtraReport report, ReportBuildProperties buildProperties) {
        report.CreateDocument();
        return null;
    }
}

See Also