InitRecord is a function on the "Sales Header" table that is called from the OnInsert trigger.
To see the code in this function Open the "Sales Header" table in design mode, Go to the last field in the list, then press F9 for the C/AL code, you will see the code for the function after the code of the last field.
Comments
¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯
On the context box it says Table36 Sales Header\OnInsert()
¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯
To see the code in this function Open the "Sales Header" table in design mode, Go to the last field in the list, then press F9 for the C/AL code, you will see the code for the function after the code of the last field.
¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯
Thank you a lot guys I learned something new and I solved my problem.