DbDataReader.GetByte(Int32) 方法

定义

在派生类中重写时,以字节形式获取指定列的值。When overridden in a derived class, gets the value of the specified column as a byte.

public:
 abstract System::Byte GetByte(int ordinal);
public abstract byte GetByte (int ordinal);
abstract member GetByte : int -> byte
Public MustOverride Function GetByte (ordinal As Integer) As Byte

参数

ordinal
Int32

从零开始的列序号。The zero-based column ordinal.

返回

Byte

指定列的值。The value of the specified column.

实现

例外

列索引超出范围。The column index is out of range.

指定的强制转换无效。The specified cast is not valid.

适用于

另请参阅