This documentation is archived and is not being maintained.
DictField.stringLen Method [AX 2012]
Returns the string size of the field if the base type of the field is a string.
Run On
Called
Return Value
Type:
int
The string size of the field if the base type of the field is a string; otherwise, 0 (zero).
The following example shows retrieving the string length of a field.
DictField df;
df = new DictField(tablenum(CustTable), fieldnum(CustTable, AccountNum));
if (df)
{
print strfmt("The string length is %1.", df.stringLen());
}