DictFieldGroup.numberOfFields Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Returns the number of table fields and edit and display methods in the field group.
public:
virtual int numberOfFields();
public virtual int numberOfFields ();
abstract member numberOfFields : unit -> int
override this.numberOfFields : unit -> int
Public Overridable Function numberOfFields () As Integer
Returns
The number of table fields and edit and display methods in the field group.
Remarks
The following example shows the retrieval of the number of table fields and edit and display methods in a field group.
DictFieldGroup fldGrp;
DictField fld;
fieldId fldId;
tableId tblId;
int i;
tblId = tablenum("CustTable");
fldGrp = new DictFieldGroup(tblId,"AutoReport");
if (fldGrp)
{ for (i=1; i <= fldGrp.numberOfFields(); i++)
{
fldId = fldGrp.field(i);
fld = new DictField(tblId, fldId);
if (fld)
{
print 'Field: ' + fld.name()
+ ' (' + int2str(fldId) + ')';
}
else
{
print 'MethodName: ' + fldGrp.methodName(fldId)
+ ' (' + int2str(fldId) + ')';
}
}
}