[FormControlEventHandler(formControlStr(EcoResProductCreate, SAZBaseItemIdentification_ItemId), FormControlEventType::Modified)] public static void SAZBaseItemIdentification_ItemId_OnModified(FormControl sender, FormControlEventArgs e) { formRun callerForm = sender.formRun(); FormStringControl senderStringControl = sender as FormStringControl; FormStringControl ProductLifecycleStateIdStringCtrl = callerForm.design().controlName(formControlStr(EcoResProductCreate, ProductLifecycleStateId)) as FormStringControl; InventTable inventTable = InventTable::find(senderStringControl.valueStr()); if(inventTable) { if (callerForm && formHasMethod(callerForm, identifierstr(templateRecords2Controls))) { //setting data 2 Ecorsproduct controls callerForm.templateRecords2Controls(BaseItemTemplateHelper::construct().dataSourceListWithRecordMap(inventTable.ItemId)); } } senderStringControl.text(inventTable.RecId != 0 ? inventTable.ItemId : strMin()); }
This blog is contains coding reference related to Microsoft AX 2012 and D365 finance and operations and Power platform
Monday, April 12, 2021
Form control Modified event handler in D365fo
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment