开发者

Axapta: Find table by name in AOT

I would like to query the AO开发者_JS百科T to see if a table name exists using X++. Can anyone point me in the right direction or provide some sample code for doing that?

If table exists with the name (str tableName) provided, return true; else, return false.


You can use the tableName2Id function. It will return 0 if the table name isn't valid.

boolean IsValidTable(str _tableName)
{
    return tableName2Id(_tableName)==0 ? false : true;
}
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜