Windows apps
Collapse the table of content
Expand the table of content
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

DbDataReader::FieldCount Property

 

Gets the number of columns in the current row.

Namespace:   System.Data.Common
Assembly:  System.Data (in System.Data.dll)

public:
property int FieldCount {
	virtual int get() abstract;
}

Property Value

Type: System::Int32

The number of columns in the current row.

Exception Condition
NotSupportedException

There is no current connection to an instance of SQL Server.

Includes hidden fields. Use VisibleFieldCount to exclude hidden fields.

Universal Windows Platform
Available since 10
.NET Framework
Available since 2.0
Return to top
Show:
© 2017 Microsoft