How to instantiate a common type object (the table's base class in AX) via a TableId
?
Furthermore what else can we do with TableId?
My goal is to send tableid
to my method and there, I will make the buffer of the table the id belongs to. Is it possible?
It can be done like this:
public static Common makeRecord(TableId _tableId)
{
return new DictTable(_tableId).makeRecord();
}
maqk
Yes you can do this. Here is a webpage explaining: http://www.doens.be/2009/07/select-a-record-from-a-table-when-you-only-have-the-tableid/
来源:https://stackoverflow.com/questions/10095415/how-to-get-a-common-object-from-a-table-id