Tuesday, January 7, 2014

AX 2012 - Call a Class\Method in CIL

Hi

Below the code for call a Class\Method in CIL :

    container               conparm;
    XppILExecutePermission  ilPermission;
    ;
    ilPermission = new XppILExecutePermission();
    ilPermission.assert();
    SysDictClass::invokeStaticMethodIL("test","test",conparm);
    CodeAccessPermission::revertAssert();

Enjoy!
 

No comments: