ArcObjects Library Reference (GeoDatabase)  

IFields.FieldCount Property

The number of fields in the fields collection.

[Visual Basic .NET]
Public ReadOnly Property FieldCount As Integer
[C#]
public int FieldCount {get;}
[C++]
HRESULT get_FieldCount(
  long* numFields
);
[C++]

Parameters

numFields [out, retval]   numFields is a parameter of type long

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Remarks

FieldCount is a one-based index. Therefore if you want to use IFields::FieldCount to get a particular index and use IFields::Field to get the field at the particular index, you will need to convert FieldCount to a zero-based index.

See Also

IFields Interface

.NET Snippets

Create FeatureClass

.NET Samples

Curve conversion add-in (Code Files: CurveConversionDockWin) | ViperPin tool (Code Files: ViperPinForm) | StreetMap routing (Code Files: RoutingForm) | Single line address geocoding (Code Files: SingleLineGeocodingForm) | Retrieve a color ramp from the SymbologyControl (Code Files: SymbolForm) | Migrating from VB6 to VB .NET for ArcGIS 10 (Code Files: ButtonAddIn clscopy_table_sel clsCopyTableSelection)

.NET Related Topics

Creating an address locator | How to geocode a single address | How to geocode a table of addresses | How to standardize an address | Migrating VB6 to VB.NET for ArcGIS 10 | Working with fields | Working with indexes