Hi,
From the below code you can easily validate a table field using X++ code.
static server boolean validateTable(common _common)
{
boolean ret = true;
SysDictTable dictTable;
int fldCnt, i;
fieldId fid;
;
dictTable = new SysDictTable(_common.TableId);
fldcnt = dictTable.fieldCnt();
for(i = 1; i <= fldcnt; i++)
{
fid = dictTable.fieldCnt2Id(i);
ret = ret && _common.validateField(fid);
}
info(strfmt('Validation Result :%1',ret));
return ret;
}
From the below code you can easily validate a table field using X++ code.
static server boolean validateTable(common _common)
{
boolean ret = true;
SysDictTable dictTable;
int fldCnt, i;
fieldId fid;
;
dictTable = new SysDictTable(_common.TableId);
fldcnt = dictTable.fieldCnt();
for(i = 1; i <= fldcnt; i++)
{
fid = dictTable.fieldCnt2Id(i);
ret = ret && _common.validateField(fid);
}
info(strfmt('Validation Result :%1',ret));
return ret;
}
No comments:
Post a Comment
Thanks for your time reviewing this blog.