Share via


DictField.stringLen Method

Definition

Returns the string size of the field if the base type of the field is a string.

public:
 virtual int stringLen();
public virtual int stringLen ();
abstract member stringLen : unit -> int
override this.stringLen : unit -> int
Public Overridable Function stringLen () As Integer

Returns

The string size of the field if the base type of the field is a string; otherwise, 0 (zero).

Remarks

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()); 
}

Applies to