Sunday 30 November 2014

Form calling sequence in AX 2012

Useful link:    http://msdn.microsoft.com/en-us/library/aa655101.aspx
This gives the information of method calls in the form level while
1. Opening the Form.
2. Creating/Updating/Deleting the record in the Form.
3. Closing the Form.
Sequence of Methods calls while opening the Form
Form --- init ()
Form --- Datasource --- init ()
Form --- run ()
Form --- Datasource --- execute Query ()
Form --- Datasource --- active ()

Sequence of Methods calls while closing the Form
Form --- canClose ()
Form --- close ()

Sequence of Methods calls while creating the record in the Form
Form --- Datasource --- create ()
Form --- Datasource --- initValue ()
Table --- initValue ()
Form --- Datasource --- active ()

Sequence of Method calls while saving the record in the Form
Form --- Datasource --- ValidateWrite ()
Table --- ValidateWrite ()
Form --- Datasource --- write ()
Table --- insert ()

Sequence of Method calls while deleting the record in the Form
Form --- Datasource --- validatedelete ()
Table --- validatedelete ()
Table --- delete ()
Form --- Datasource --- active ()

Sequence of Methods calls while modifying the fields in the Form
I) validateField()  -> validateFieldValue() ->  ModifiedField() ->  ModifiedFieldValue()
II) 
Table --- validateField ()
Table --- modifiedField ()

1).when form is getting closed:
canclose method get call - can close return boolean true then only close method gets called
----> Canclose()-Close().

2)Sequence of closing form using Ok command Button
----> CloseOk()-Canclose()-Close.
Cancel command Button - save record property should be set to "NO".

3)Sequence of using Command button Cancel
-----> ClosedCancel()-Canclose()-Close().

Original post here: 
http://kollidynamics.blogspot.ae/2011/08/sequence-of-methods-in-form-level-in-ax.html

No comments:

Post a Comment