Count fields

4D - Documentation   Français   English   German   4th Dimension 2004, Command Theme List   4th Dimension 2004, Command Alphabetical List   4th Dimension 2004, Constant Theme List   Back   Previous   Next

version 3


Count fields (tableNum | tablePtr) Number

ParameterTypeDescription
tableNum | tablePtrNumber | PointerTable number or Pointer to table
Function resultNumberNumber of fields in table

Description

The Count fields command returns the number of fields in the table whose number or pointer you pass in tableNum or tablePtr.

Fields are numbered in the order in which they are created.

Example

The following project method builds the array asFields, consisting of the field names, for the table whose pointer is received as first parameter:

   $vlTable:=Table($1)
   ARRAY STRING(31;asFields;Count fields($vlTable))
   For ($vlField;1;Size of array(asFields))
      asFields{$vlField}:=Field name($vlTable;$vlField)
   End for

See Also

Count tables, Field name, GET FIELD PROPERTIES.


4D - Documentation   Français   English   German   4th Dimension 2004, Command Theme List   4th Dimension 2004, Command Alphabetical List   4th Dimension 2004, Constant Theme List   Back   Previous   Next