Quantcast
Channel: Martin Dráb's Activities
Viewing all articles
Browse latest Browse all 17532

How can I open specific form and specific record from C#application

$
0
0
 Hi.
I develop at AX 2012 R3 + C#.
How can I open specific form and specific record from C# application.
I want to open specific form and specific record that was set parameters from C# application.
I wonder it might possible use .NET proxy.

 

I use this code in X++.(Classes\Batch1)

static void main(Args _args = null)
{
    MenuFunction menuFunction;
    CustTable _custTable;
    _args = new Args();

    _custTable = CustTable::find("DAT-000001");
    menuFunction = new MenuFunction(menuitemDisplayStr(CustTable), MenuItemType::Display);

    _args.record(_custTable);
    menuFunction.run();
}


And I use this code in C#.

using (Session session = new Session())
{
     session.Logon("DAT", null, null, null);
     Batch1 tmpBatch = new Batch1();
     Batch1.main();
 }

Try this code, it seems done successfully, but not open custform. Is it impossible?

I refer to this URL too: community.dynamics.com/.../152359


Viewing all articles
Browse latest Browse all 17532


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>