✏️ Explanatory Question
A static constructor in X++ is defined using:
static void TypeNew()
It is automatically executed:
Before any static method call.
Before any instance method call.
Only once per session.
Important characteristics:
Cannot be explicitly called.
Cannot accept parameters.
Must be marked as static.
Used to initialize static fields.
The compiler guarantees that the static constructor runs exactly one time before the class is used.