PrintableComponentContainer Class

A container for DevExpress and third-party Windows Forms controls, as well as controls implementing the IPrintable interface and documents created using printing links.

Namespace: DevExpress.XtraReports.UI

Assembly: DevExpress.XtraReports.v18.2.dll

Declaration

[ToolboxTabName("DX.18.2: Report Controls")]
[ToolboxBitmap(typeof(PrintableComponentContainer))]
[XRDesigner("DevExpress.XtraReports.Design.PrintableComponentContainerDesigner,DevExpress.XtraReports.v18.2.Extensions, Version=18.2.99.0, Culture=neutral, PublicKeyToken=c38a27d2243c2672")]
[XRToolboxSubcategory(1, 4)]
public class PrintableComponentContainer :
    WinControlContainer
<ToolboxTabName("DX.18.2: Report Controls")>
<ToolboxBitmap(GetType(PrintableComponentContainer))>
<XRDesigner("DevExpress.XtraReports.Design.PrintableComponentContainerDesigner,DevExpress.XtraReports.v18.2.Extensions, Version=18.2.99.0, Culture=neutral, PublicKeyToken=c38a27d2243c2672")>
<XRToolboxSubcategory(1, 4)>
Public Class PrintableComponentContainer
    Inherits WinControlContainer
    Implements

Remarks

To print a control or a printing link, assign it to the PrintableComponentContainer.PrintableComponent property in code:

using System.Windows.Forms;

// Create a new report instance. 
XtraReport1 report = new XtraReport1();

// Link the required control (for instance, the Grid Control) with the PrintableComponentContainer of a report. 
report.printableComponentContainer1.PrintableComponent = gridControl;

// Invoke a Print Preview for the created report document.  
ReportPrintTool preview = new ReportPrintTool(report);
preview.ShowRibbonPreview();

See Using Third-Party Controls to learn about using the PrintableComponentContainer for embedding DevExpress controls to a report.

Inheritance

Implements

DevExpress.XtraReports.Serialization.IXRSerializable
DevExpress.Utils.Serializing.Helpers.IXtraSupportDeserializeCollectionItem
DevExpress.Utils.Serializing.IXtraSerializable
See Also