How to get field type in dynamics ax 2012 using x++
display FieldType fieldType()
{
FieldType ret;
DictField dictField;
TableId tableId = tableNum(PurchLine);
FieldId fieldId = fieldName2id(tableId,"Field Name");
if(tableId && fieldId)
{
dictField = new DictField(tableId,fieldId);
ret = dictField.baseType();
}
return ret;
}
{
FieldType ret;
DictField dictField;
TableId tableId = tableNum(PurchLine);
FieldId fieldId = fieldName2id(tableId,"Field Name");
if(tableId && fieldId)
{
dictField = new DictField(tableId,fieldId);
ret = dictField.baseType();
}
return ret;
}
Comments
Post a Comment