次の方法で共有


SqlDataReader.GetDouble メソッド

指定した列の値を倍精度浮動小数点数として取得します。

Public Overridable Function GetDouble( _
   ByVal i As Integer _) As Double Implements IDataRecord.GetDouble
[C#]
public virtual double GetDouble(inti);
[C++]
public: virtual double GetDouble(inti);
[JScript]
public function GetDouble(
   i : int) : double;

パラメータ

  • i
    列の 0 から始まる序数。

戻り値

指定した列の値。

実装

IDataRecord.GetDouble

例外

例外の種類 条件
InvalidCastException 指定したキャストが有効ではありません。

解説

変換は実行されません。そのため、取得するデータは倍精度浮動小数点数である必要があります。

このメソッドを呼び出す前に、 IsDBNull を呼び出して、null 値を確認してください。

必要条件

プラットフォーム: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 ファミリ, .NET Compact Framework - Windows CE .NET

参照

SqlDataReader クラス | SqlDataReader メンバ | System.Data.SqlClient 名前空間