How to enable/disable a textbox in Form C which is called from Form A/Form B??

Hi all,

im new to Microsoft Dynamic AX…i was working in .Net previously. I have a Form C which contains some textboxes with values. Form A and Form B calls Form C. What i need is when Form A calls Form C, controls shud be enabled and when Form B calls Form C, controls should be disabled. i know we can use args() to do this but i tried my best to use args() and pass it from Form A,B to Form C…But still the result either is its enabled when both the forms call Form C or it is disabled when both the forms call Form C which means default setting is saved…My code to enable/disable even though is triggering but is not having an effect on Form C…

//PurchParmTabletotals is my Form C

The code which i wrote in Form A is:

Args args = new Args();

FormRun formRun;


formRun = classFactory.formRunClass(args);









formrun.wait in ur caller form (form A)

in ur called form (form C) in init method,

formrun callerform;

callerform = element.args().caller();

if( == formstr(formA))

//your logic here

Thanks a lot Narayan…It worked!!!

Hi Cyril,

Welcome to DUG [:)] and glad you got the solution. If somebody’s reply helped you, please remember to mark it as verified solution.