Share via


ReportParameterCollection.Add Method

Definition

Overloads

Add(ReportParameter)

Adds the specified ReportParameter to the end of the collection.

Add(String, String)

Creates a new ReportParameter object using the name and value provided, adds it to the collection and returns the new ReportParameter object created.

Add(ReportParameter)

Adds the specified ReportParameter to the end of the collection.

public int Add (Microsoft.AnalysisServices.ReportParameter item);
member this.Add : Microsoft.AnalysisServices.ReportParameter -> int
Public Function Add (item As ReportParameter) As Integer

Parameters

item
ReportParameter

The ReportParameter to be added.

Returns

The zero-based index at which the ReportParameter has been added to the collection.

Exceptions

The specified item is a null reference (Nothing in Visual Basic).

The specified item's name is a null reference (Nothing in Visual Basic).

  • The specified item already esists in the collection.
  • The specified item belongs to another collection.
  • The collection already contains an item with the same name as the specified item.

Applies to

Add(String, String)

Creates a new ReportParameter object using the name and value provided, adds it to the collection and returns the new ReportParameter object created.

public Microsoft.AnalysisServices.ReportParameter Add (string name, string value);
member this.Add : string * string -> Microsoft.AnalysisServices.ReportParameter
Public Function Add (name As String, value As String) As ReportParameter

Parameters

name
String

The Name for the new ReportParameter object.

value
String

The Value for the new ReportParameter object.

Returns

The newly created ReportParameter object.

Exceptions

The specified name is a null reference (Nothing in Visual Basic).

The collection already contains an item with the same name as the specified name.

Applies to