Find field name against a table

static void findAllFieldsNameFromTable(Args _args)
{
    tableId tableId = tableNum(ProjTable);

    DictTable dictTable = new DictTable(tableId);
    fieldId fieldId;
    dictField dictField;
    int i;
   
    for (i = 1; i<=dictTable.fieldCnt(); i++)
    {
        fieldId = dictTable.fieldCnt2Id(i);
        dictField = new DictField(tableId, fieldId);
        info(dictField.name());
    }
}

Advertisements
%d bloggers like this: