Hi guys,
I activated Subscription Billing feature, and in Sales Order, in the Line action pane section there is a button labeled "Deferrals"
when clicked it will pop up window for Deferral's process.->
I want to modified this setting to make some default. Question is how to know which class I need to modified ? What or how is the best way to know where is the handling when form is loaded, because I think I need to modified right before the form is displayed.
I tried to create Event Handler class, in the form "SubBillDeferralTransactionDeferral", I believe this is the pop up form, event handler in their "SubBillDeferralTransactionDeferral_OnInitialized", just adding "info("hi")" and put a breakpoint, but seems it is not the right place since I cannot see of what other class or function makes the value.
I actually beginner on this development, may need some guidance of what is the best way to identify this in D365 FO development.
Thanks,
You can try creating Event Handler or CoC on OnInitialized method of this form and set default value in the Deferral parameter. If you want this for Sales orders only then just li.ke standard code, you can check if its for SalesLine.
Hi Mohit,
Thanks,
I actually already put breakpoint on that Init() method, however it won't stop when debugging. then the form just come out as it is.
I also put another breakpoint in that Switch case, there is one case which is the case is SalesLine ->
Also as mentioned, debug not stopped, so I cannot determine what to create in order to modified the default value of the form before it is finish loading.
Just for example, I want to make the Deferred value to always "Yes"
Anyway I need to find out the call stack first, which currently I didn't know because the debug won't stop at the given breakpoint.
Thanks
Hi, SubBillDeferralTransactionDeferral seems to be correct form that is called from Deferrals button. You can add breakpoint in init method of this form.
In the form itself "SubBillDeferralTransactionLineDeferral", there is void called "initFromSalesLine". I thought this is the code which handling the defaulting value. I put some breakpoint in it, however it is not stopped when I'm doing debug.
Anyway, I'm asking how "in general" is the best way and practical way (and fastest way) to know this kind of thing in D365 F&O development, if my question is too specific.
Thanks
André Arnaud de Cal...
292,074
Super User 2025 Season 1
Martin Dráb
230,900
Most Valuable Professional
nmaenpaa
101,156