ReportDataSource Class

 

Represents a data source for a report.

Namespace:   Microsoft.Reporting.WinForms
Assembly:  Microsoft.ReportViewer.WinForms (in Microsoft.ReportViewer.WinForms.dll)

Inheritance Hierarchy

System.Object
  Microsoft.Reporting.WinForms.ReportDataSource

Syntax

public sealed class ReportDataSource
public ref class ReportDataSource sealed 
[<Sealed>]
type ReportDataSource = class end
Public NotInheritable Class ReportDataSource

Constructors

Name Description
System_CAPS_pubmethod ReportDataSource()

Constructs an empty data source.

System_CAPS_pubmethod ReportDataSource(String)

Constructs a named data source.

System_CAPS_pubmethod ReportDataSource(String, BindingSource)

Constructs a named data source with a BindingSource object in the Value property.

System_CAPS_pubmethod ReportDataSource(String, DataTable)

Constructs a named data source with a DataTable object in the Value property.

System_CAPS_pubmethod ReportDataSource(String, IEnumerable)

Constructs a named data source with an IEnumerable object in the Value property.

System_CAPS_pubmethod ReportDataSource(String, Object)

Constructs a named data source with a value.

System_CAPS_pubmethod ReportDataSource(String, Type)

Constructs a named data source with the Value property initialized as a particular type.

Properties

Name Description
System_CAPS_pubproperty Name

Gets or sets the name of the report data source.

System_CAPS_pubproperty Value

Gets or sets the instance of the report data source.

Methods

Name Description
System_CAPS_pubmethod Equals(Object)

(Inherited from Object.)

System_CAPS_pubmethod GetHashCode()

(Inherited from Object.)

System_CAPS_pubmethod GetType()

(Inherited from Object.)

System_CAPS_pubmethod ToString()

(Inherited from Object.)

Remarks

The ReportDataSource class is used with the DataSources collection of a LocalReport object to add one or more required data sources to a local report. This is necessary when adding a report to the ReportViewer control.

Examples

Legacy Code Example

For code examples, see LocalReport.

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

See Also

Microsoft.Reporting.WinForms Namespace

Return to top