AccountCollection.Insert Method

Definition

Overloads

Insert(Int32, Account)

Inserts the specified Account to the collection at the specified index.

Insert(Int32, String)

Creates a new Account object using the specified account type, inserts it to the collection at the specified index and returns the new Account created.

Insert(Int32, Account)

Inserts the specified Account to the collection at the specified index.

public void Insert (int index, Microsoft.AnalysisServices.Account item);
override this.Insert : int * Microsoft.AnalysisServices.Account -> unit
Public Sub Insert (index As Integer, item As Account)

Parameters

index
Int32

The zero-based index at which the Account is inserted.

item
Account

The Account to be inserted.

Exceptions

The specified index is not a valid value (less than zero or bigger then the total number of elements).

  • The specified item is a null reference (Nothing in Visual Basic).
  • The specified item already esists in the collection.
  • The account type of the specified Account is not valid in the collection.
  • The compatibility-level of the specified Account is not valid in the collection.

Applies to

Insert(Int32, String)

Creates a new Account object using the specified account type, inserts it to the collection at the specified index and returns the new Account created.

public Microsoft.AnalysisServices.Account Insert (int index, string accountType);
override this.Insert : int * string -> Microsoft.AnalysisServices.Account
Public Function Insert (index As Integer, accountType As String) As Account

Parameters

index
Int32

The zero-based index at which the Account is inserted.

accountType
String

The account type for the new Account object.

Returns

The newly created Account object.

Exceptions

The specified index is not a valid value (less than zero or bigger then the total number of elements).

The specified account type is not valid in the collection.

Applies to