Thursday, August 4, 2022

Get source record from a caller object

Suppose you have a form A that calls form B.

In Form B you want to know what is the data source of Form A and if it’s a VendTable you wish to retrieve the AccountNum field


VendTable vendTableLocal;

switch (element.args().record().dataSource().Name())

        {

            case 'VendTable':

                vendTableLocal = element.args().record() as VendTable;

                    break;

            default:

                break;

        }

Link