New to Telerik Reporting? Start a free 30-day trial

This report source is used when you have a reference to an already instantiated report (Report instance). For better performance and compatibility use TypeReportSource. Represents a report source that contains a reference to an instance of IReportDocument.

Definition

Namespace:Telerik.Reporting

Assembly:Telerik.Reporting.dll

Syntax:

C#
public class InstanceReportSource : ReportSource

Inheritance: objectReportSourceInstanceReportSource

Inherited Members ReportSource.Parameters

Example:

The following example shows how to create an InstanceReportSource:

cs
var instanceReportSource = new Telerik.Reporting.InstanceReportSource();

// Assigning the Report object to the InstanceReportSource
instanceReportSource.ReportDocument = new Telerik.Reporting.Examples.CSharp.Invoice();

// Adding the initial parameter values
instanceReportSource.Parameters.Add(new Telerik.Reporting.Parameter("OrderNumber", "SO43659"));
vb
Dim instanceReportSource As New Telerik.Reporting.InstanceReportSource()

' Assigning the Report object to the InstanceReportSource
instanceReportSource.ReportDocument = New Invoice()

' Adding the initial parameter values
instanceReportSource.Parameters.Add(New Telerik.Reporting.Parameter("OrderNumber", "SO43659")) 

Constructors

Initializes a new instance of the InstanceReportSource class.

C#
public InstanceReportSource()

Properties

Gets or sets the IReportDocument instance for the report source.

C#
public IReportDocument ReportDocument { get; set; }

Methods

Determines whether this instance and a specified object have the same value.

C#
public override bool Equals(object obj)
Parameters:objobject

The object to compare with this instance.

Returns:

bool

true if obj is an InstanceReportSource and its value is the same as this instance; otherwise, false.

Overrides: ReportSource.Equals(object)

Returns the hash code for this InstanceReportSource.

C#
public override int GetHashCode()
Returns:

int

A 32-bit signed integer hash code.

Overrides: ReportSource.GetHashCode()

Returns a string that represents the current InstanceReportSource.

C#
public override string ToString()
Returns:

string

A string that represents the ReportDocument of this InstanceReportSource, or an empty string if ReportDocument is null.

Overrides: ReportSource.ToString()