web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :

AX 2012: How to open a form in X++

M Anas Khan Profile Picture M Anas Khan 1,424

Using FormRun:

void clicked()
{
    Args    args;
    FormRun formRun;
	
    args = new Args(formstr(CustTable));
    args.record(custTableLocal);
    formRun = classFactory.formRunClass(args);
    formRun.init();
    formRun.run();
    formRun.wait();
    formRun.detach();
    CustTable_DS.research();
}

Using MenuFunction:

void clicked()
{
    Args args;
	
    args = new Args();
    args.caller(this);
    args.parmObject(list);
    new MenuFunction(menuItemDisplayStr(SalesTable), MenuItemType::Display).run(args);
}


This was originally posted here.

Comments

*This post is locked for comments