Xafari Reports. Xtra Reports VS Designer

Xafari Reports provides the design of XtraReports templates in Visual Studio using the DevExpress designer (see https://documentation.devexpress.com/#eXpressAppFramework/CustomDocument112734).

Before design a template, you must implement and build the Xafari Report. The template design process is similar to the one for Reports V2, specific difference is the data source, you must use XafariReportDataSource. To add XafariReportDataSource, invoke Toolbox and navigate to the XAFARI x08: XAFARI Data Sources for Reports. Set ReportType property of the XafariReportDataSource to the required value:  

reports_20

To deploy designed Template, use ObjectSpace extension method defined in the Xafari.Reports.Xaf.TemplateDeployment class:

public static XafXafariReportTemplate DeployPredefinedXtraTemplate<T>(this IObjectSpace, string, bool) where T : XtraReport

The code snippet below demonstrates how to deploy MyXtraTemplate Template:

  • c#
  • VB

public void smth()
{
  using (var objectSpace = Application.CreateObjectSpace())
  {
    objectSpace.DeployPredefinedXtraTemplate<MyXtraTemplate>("My XtraReport template");
  }
}

Public Sub smth()
  Using objectSpace = Application.CreateObjectSpace()
    objectSpace.DeployPredefinedXtraTemplate(Of MyXtraTemplate)("My XtraReport template")
  End Using
End Sub