Condividi tramite


Classe RowIndexOutOfRangeException

The exception that is thrown when an invalid index is supplied when accessing a row in a PipelineBuffer.

Gerarchia di ereditarietà

System. . :: . .Object
  System. . :: . .Exception
    System. . :: . .ApplicationException
      Microsoft.SqlServer.Dts.Pipeline..::..RowIndexOutOfRangeException

Spazio dei nomi  Microsoft.SqlServer.Dts.Pipeline
Assembly:  Microsoft.SqlServer.PipelineHost (in Microsoft.SqlServer.PipelineHost.dll)

Sintassi

'Dichiarazione
<SerializableAttribute> _
Public Class RowIndexOutOfRangeException _
    Inherits ApplicationException
'Utilizzo
Dim instance As RowIndexOutOfRangeException
[SerializableAttribute]
public class RowIndexOutOfRangeException : ApplicationException
[SerializableAttribute]
public ref class RowIndexOutOfRangeException : public ApplicationException
[<SerializableAttribute>]
type RowIndexOutOfRangeException =  
    class
        inherit ApplicationException
    end
public class RowIndexOutOfRangeException extends ApplicationException

Nel tipo RowIndexOutOfRangeException sono esposti i membri seguenti.

Costruttori

  Nome Descrizione
Metodo pubblico RowIndexOutOfRangeException Initializes a new instance of the RowIndexOutOfRangeException class.

In alto

Proprietà

  Nome Descrizione
Proprietà pubblica Data Ereditato da Exception.
Proprietà pubblica HelpLink Ereditato da Exception.
Proprietà protetta HResult Ereditato da Exception.
Proprietà pubblica InnerException Ereditato da Exception.
Proprietà pubblica Message Ereditato da Exception.
Proprietà pubblica Source Ereditato da Exception.
Proprietà pubblica StackTrace Ereditato da Exception.
Proprietà pubblica TargetSite Ereditato da Exception.

In alto

Metodi

  Nome Descrizione
Metodo pubblico Equals Ereditato da Object.
Metodo protetto Finalize Ereditato da Object.
Metodo pubblico GetBaseException Ereditato da Exception.
Metodo pubblico GetHashCode Ereditato da Object.
Metodo pubblico GetObjectData Ereditato da Exception.
Metodo pubblico GetType Ereditato da Exception.
Metodo protetto MemberwiseClone Ereditato da Object.
Metodo pubblico ToString Ereditato da Exception.

In alto

Osservazioni

This exception is thrown when attempting to access a row in a PipelineBuffer by index and the supplied index is either greater than the number of rows in the buffer or is less than zero.

Accessing the CurrentRow property of the PipelineBuffer object without first calling NextRow will also throw this exception because the CurrentRow property has not been advanced to the first row in the collection.

Esempi

The following code example throws a RowIndexOutOfRangeException because NextRow has not been called first.

public override void ProcessInput(int inputID, PipelineBuffer buffer)
{
try
{
//while (buffer.NextRow())
//{
BufferColumn bc = buffer.GetColumnInfo(0);
//}
}
catch (RowIndexOutOfRangeException e )
{
}
}
Public Overloads Overrides Sub ProcessInput(ByVal inputID As Integer, ByVal buffer As PipelineBuffer) 
 Try 
   Dim bc As BufferColumn = buffer.GetColumnInfo(0) 
 Catch e As RowIndexOutOfRangeException 
 End Try 
End Sub

Protezione dei thread

I membri static (Shared in Visual Basic) pubblici di questo tipo sono affidabili. Non è invece garantita la sicurezza dei membri dell'istanza.